-
Notifications
You must be signed in to change notification settings - Fork 2k
Closed
Labels
formatterRelated to the formatterRelated to the formatterstyleHow should formatted code lookHow should formatted code look
Description
Summary
Source:
a = []
b = []
match a, b:
case [], []:
...
case [], _:
...
case _, []:
...
case _, _:
...Formatted:
a = []
b = []
match a, b:
case [[], []]:
...
case [[], _]:
...
case _, []:
...
case _, _:
...It seems rather inconsistent that the formatter adds wrapping [] on the first two cases but not the others.
Edit: for reference, Black leaves the original file unchanged.
Version
ruff 0.11.7 (f7b4851 2025-04-24)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
formatterRelated to the formatterRelated to the formatterstyleHow should formatted code lookHow should formatted code look