From 0967bf2a363a5c39c23f6d02b6767a74968a5ccc Mon Sep 17 00:00:00 2001 From: Yilei Yang Date: Mon, 19 Dec 2022 11:00:16 -0800 Subject: [PATCH] Move the concatenated string wrapping in paren diff to the "historical" section. https://github.com/psf/black/pull/3307 is merged. PiperOrigin-RevId: 496442325 --- README.md | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/README.md b/README.md index d8beecf8a42..73afee28ed6 100644 --- a/README.md +++ b/README.md @@ -83,27 +83,6 @@ patches as possible in the future. ) ``` -* Wrap concatenated strings in parens for function arguments (see - [psf/black#3292](https://github.com/psf/black/issues/3292)). Example: - - ```python - # Pyink: - function_call( - ( - " lorem ipsum dolor sit amet consectetur adipiscing elit sed do eiusmod tempor" - " incididunt ut labore et dolore magna aliqua Ut enim ad minim" - ), - " veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo", - ) - - # Black: - function_call( - " lorem ipsum dolor sit amet consectetur adipiscing elit sed do eiusmod tempor" - " incididunt ut labore et dolore magna aliqua Ut enim ad minim", - " veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo", - ) - ``` - * Add an empty line between class statements without docstrings, and the first method. We expect we will simply remove this difference from *Pyink* at some point. Example: @@ -126,6 +105,27 @@ patches as possible in the future. These are differences that existed in the past. We have upstreamed them to *Black* so they are now identical. +* Wrap concatenated strings in parens for function arguments (see + [psf/black#3292](https://github.com/psf/black/issues/3292)). Example: + + ```python + # New: + function_call( + ( + " lorem ipsum dolor sit amet consectetur adipiscing elit sed do eiusmod tempor" + " incididunt ut labore et dolore magna aliqua Ut enim ad minim" + ), + " veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo", + ) + + # Old: + function_call( + " lorem ipsum dolor sit amet consectetur adipiscing elit sed do eiusmod tempor" + " incididunt ut labore et dolore magna aliqua Ut enim ad minim", + " veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo", + ) + ``` + * Prefer splitting right hand side of assignment statements (see [psf/black#1498](https://github.com/psf/black/issues/1498). Example: