Skip to content

formatOnType strips spacing around = for comma-trailing statements #1787

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
brettcannon opened this issue May 29, 2018 · 4 comments · Fixed by #1824
Closed

formatOnType strips spacing around = for comma-trailing statements #1787

brettcannon opened this issue May 29, 2018 · 4 comments · Fixed by #1824
Assignees
Labels
area-formatting bug Issue identified by VS Code Team member as probable bug
Milestone

Comments

@brettcannon
Copy link
Member

b = {a: b, c: d,
}

becomes:

b={a: b, c: d,
}
@brettcannon brettcannon added bug Issue identified by VS Code Team member as probable bug needs PR area-formatting labels May 29, 2018
@brettcannon brettcannon changed the title formatOnType strips spacing around = for multi-line dicts formatOnType strips spacing around = for comma-trailing statements May 29, 2018
@brettcannon
Copy link
Member Author

a = 1,

becomes:

a=1,

@brettcannon
Copy link
Member Author

d= 1, b, c,

becomes:

d=1, b, c,

@brettcannon
Copy link
Member Author

foo = long_function_name(var_one, var_two,
)

becomes:

foo=long_function_name(var_one, var_two,
)

@MikhailArkhipov
Copy link

Yep since they look like

foo(a,
b=1,c,
d)

@MikhailArkhipov MikhailArkhipov self-assigned this May 30, 2018
@MikhailArkhipov MikhailArkhipov added this to the May 2018 milestone May 30, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Jul 10, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-formatting bug Issue identified by VS Code Team member as probable bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants