Fix spurious space in parenthesized set expressions

Fixes #7
This commit is contained in:
Łukasz Langa 2018-03-15 11:28:59 -07:00 committed by Lukasz Langa
parent e1e89091d1
commit 174fc47b78
3 changed files with 11 additions and 0 deletions

View File

@ -255,6 +255,8 @@ You can still try but prepare to be disappointed.
* fixed invalid spacing of dots in relative imports (#6, #13)
* fixed spurious space in parenthesized set expressions (#7)
### 18.3a0

View File

@ -895,6 +895,7 @@ def whitespace(leaf: Leaf) -> str:
syms.or_test,
syms.and_test,
syms.arith_expr,
syms.expr,
syms.shift_expr,
syms.yield_expr,
syms.term,

View File

@ -106,6 +106,8 @@
b = 1,
c = 1
d = (1,) + a + (2,)
what_is_up_with_those_new_coord_names = (coord_names + set(vars_to_create)) + set(vars_to_remove)
what_is_up_with_those_new_coord_names = (coord_names | set(vars_to_create)) - set(vars_to_remove)
def gen():
@ -228,6 +230,12 @@ async def f():
b = 1,
c = 1
d = (1,) + a + (2,)
what_is_up_with_those_new_coord_names = (coord_names + set(vars_to_create)) + set(
vars_to_remove
)
what_is_up_with_those_new_coord_names = (coord_names | set(vars_to_create)) - set(
vars_to_remove
)
def gen():