mirror of https://github.com/astral-sh/ruff
add broken test cases
the new leading comment is causing the whole Parameters list to break. these
cases should instead format like:
```py
(
lambda
# comment
*x, **y: x
)
(
lambda
# comment 2
*x, **y: x
)
```
without line breaks in the parameter list
This commit is contained in:
parent
0bec5c0362
commit
90f43bde84
|
|
@ -249,3 +249,25 @@ def a():
|
||||||
x:
|
x:
|
||||||
x
|
x
|
||||||
)
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
# comment
|
||||||
|
*x,
|
||||||
|
**y: x
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
* # comment 2
|
||||||
|
x,
|
||||||
|
**y:
|
||||||
|
x
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
** # comment 1
|
||||||
|
x:
|
||||||
|
x
|
||||||
|
)
|
||||||
|
|
|
||||||
|
|
@ -255,6 +255,28 @@ def a():
|
||||||
x:
|
x:
|
||||||
x
|
x
|
||||||
)
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
# comment
|
||||||
|
*x,
|
||||||
|
**y: x
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
* # comment 2
|
||||||
|
x,
|
||||||
|
**y:
|
||||||
|
x
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
** # comment 1
|
||||||
|
x:
|
||||||
|
x
|
||||||
|
)
|
||||||
```
|
```
|
||||||
|
|
||||||
## Output
|
## Output
|
||||||
|
|
@ -513,4 +535,24 @@ def a():
|
||||||
# comment 2
|
# comment 2
|
||||||
*x: x
|
*x: x
|
||||||
)
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
# comment
|
||||||
|
*x,
|
||||||
|
**y: x
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
# comment 2
|
||||||
|
*x,
|
||||||
|
**y: x
|
||||||
|
)
|
||||||
|
|
||||||
|
(
|
||||||
|
lambda
|
||||||
|
# comment 1
|
||||||
|
**x: x
|
||||||
|
)
|
||||||
```
|
```
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue