Improved string processing: add parentheses around implicit string concatenations to increase readability in certain contexts #3159
Labels
F: parentheses
Too many parentheses, not enough parentheses, and so on.
F: strings
Related to our handling of strings
S: accepted
The changes in this design / enhancement issue have been accepted and can be implemented
T: style
What do we want Blackened code to look like?
Describe the style change
When splitting long string literals in Black's
--preview
Improved string processing style, add parentheses around implicit string concatenations to increase readability in certain contexts."certain contexts" include:
Examples of unformatted code
Examples in the current Black style
Desired style
Additional context
This issue was raised originally in #2188 (comment). Per @JelleZijlstra, I'm starting a new issue separately here to track the work.
The "certain contexts" list isn't exhaustive. I plan to read the code and play around with an implementation, then report back here.
The text was updated successfully, but these errors were encountered: