Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
cc318ee
bpo-28002: Roundtrip f-strings with ast.unparse better
Apr 19, 2020
4743d8d
Update Lib/ast.py
hauntsaninja May 21, 2020
98878ba
_Unparser: make avoid_backslashes keyword only
May 22, 2020
a0a7b26
test_unparse: add test_fstring to run_always_files
May 22, 2020
0c95e56
unparse fstrings: improve cosmetics by escaping whitespace
Jun 3, 2020
ac49be1
unparse: add another test case
Jun 3, 2020
714a269
unparse: fix final quote escaping issues
Jun 3, 2020
85521c0
unparse: simplify, share code with docstring writing
Jun 3, 2020
106cdd2
Merge remote-tracking branch 'upstream/master' into astunparse
Jun 3, 2020
4e4a4b4
remove comment
Jun 3, 2020
91430f5
reduce assignments to qts
Jun 4, 2020
81ff3cb
use join instead of multiple replace
Jun 4, 2020
bd05428
use write_str_avoiding_backslashes for docstrings
Jun 4, 2020
cd2c107
don't use replace for backslashes
Jun 4, 2020
4a7037a
use isprintable
Jun 4, 2020
228f0b3
fix comment
Jun 4, 2020
debc3dd
Use American English
Jun 7, 2020
32d34e6
s/qts/possible_quotes/g
Jun 7, 2020
1fdb075
Prefix undesrscore to avoid_backslashes
Jun 7, 2020
c3fd073
Rename value and val
Jun 7, 2020
a3b48a0
Reformat string escaping
Jun 7, 2020
84485ab
Add a comment to visit_JoinedStr
Jun 7, 2020
4f32cf0
Fix line lengths
Jun 7, 2020
d31b376
Update comment for variable name change
Jun 7, 2020
428fab7
move variable from start of __init__ to end
Oct 18, 2020
ec38952
use global constants for quote types
Oct 18, 2020
b903dcf
make docstring explicit about returning a tuple
Oct 18, 2020
007bb4a
use kw only args
Oct 18, 2020
4c09b96
add escape_special_whitespace boolean argument
Oct 18, 2020
7735da5
use an inner function instead of a comprehension
Oct 18, 2020
593b0d2
add to comment when falling back to repr
Oct 18, 2020
fc6166f
swap the order of the iterations to save a little effort
Oct 18, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
remove comment
  • Loading branch information
hauntsaninja
hauntsaninja committed Jun 3, 2020
commit 4e4a4b49d1c11fbb1857bb4bb55078509750eee7
1 change: 0 additions & 1 deletion Lib/ast.py
Original file line number Diff line number Diff line change
Expand Up @@ -1114,7 +1114,6 @@ def visit_JoinedStr(self, node):
meth = getattr(self, "_fstring_" + type(value).__name__)
meth(value, self.buffer_writer)
buffer.append((self.buffer, isinstance(value, Constant)))
# This part is analagous to _write_str_avoiding_backslashes
new_buffer = []
quote_types = ["'", '"', '"""', "'''"]
for value, is_constant in buffer:
Expand Down