-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace LALRPOP parser with hand-written parser
Co-authored-by: Micha Reiser <[email protected]>
- Loading branch information
1 parent
af6ea2f
commit a695672
Showing
253 changed files
with
37,834 additions
and
5,615 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
...uff_linter/src/rules/isort/snapshots/ruff_linter__rules__isort__tests__bom_sorted.py.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,17 @@ | ||
--- | ||
source: crates/ruff_linter/src/rules/isort/mod.rs | ||
--- | ||
bom_sorted.py:1:1: I001 [*] Import block is un-sorted or un-formatted | ||
| | ||
1 | import bar | ||
| _^ | ||
2 | | import foo | ||
| | ||
= help: Organize imports | ||
|
||
ℹ Safe fix | ||
1 |-import bar | ||
2 |-import foo | ||
1 |+import rt | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 3 additions & 7 deletions
10
...src/rules/pycodestyle/snapshots/ruff_linter__rules__pycodestyle__tests__E999_E999.py.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,8 @@ | ||
--- | ||
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs | ||
--- | ||
E999.py:3:1: E999 SyntaxError: unindent does not match any outer indentation level | ||
| | ||
2 | def x(): | ||
3 | | ||
| ^ E999 | ||
4 | | ||
| | ||
E999.py:5:1: E999 SyntaxError: expected a single statement or an indented body after function definition | ||
| | ||
| | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
110 changes: 0 additions & 110 deletions
110
..._linter/src/rules/pyupgrade/snapshots/ruff_linter__rules__pyupgrade__tests__UP027.py.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,114 +1,4 @@ | ||
--- | ||
source: crates/ruff_linter/src/rules/pyupgrade/mod.rs | ||
--- | ||
UP027.py:2:17: UP027 [*] Replace unpacked list comprehension with a generator expression | ||
| | ||
1 | # Should change | ||
2 | foo, bar, baz = [fn(x) for x in items] | ||
| ^^^^^^^^^^^^^^^^^^^^^^ UP027 | ||
3 | | ||
4 | foo, bar, baz =[fn(x) for x in items] | ||
| | ||
= help: Replace with generator expression | ||
|
||
ℹ Safe fix | ||
1 1 | # Should change | ||
2 |-foo, bar, baz = [fn(x) for x in items] | ||
2 |+foo, bar, baz = (fn(x) for x in items) | ||
3 3 | | ||
4 4 | foo, bar, baz =[fn(x) for x in items] | ||
5 5 | | ||
|
||
UP027.py:4:16: UP027 [*] Replace unpacked list comprehension with a generator expression | ||
| | ||
2 | foo, bar, baz = [fn(x) for x in items] | ||
3 | | ||
4 | foo, bar, baz =[fn(x) for x in items] | ||
| ^^^^^^^^^^^^^^^^^^^^^^ UP027 | ||
5 | | ||
6 | foo, bar, baz = [fn(x) for x in items] | ||
| | ||
= help: Replace with generator expression | ||
|
||
ℹ Safe fix | ||
1 1 | # Should change | ||
2 2 | foo, bar, baz = [fn(x) for x in items] | ||
3 3 | | ||
4 |-foo, bar, baz =[fn(x) for x in items] | ||
4 |+foo, bar, baz =(fn(x) for x in items) | ||
5 5 | | ||
6 6 | foo, bar, baz = [fn(x) for x in items] | ||
7 7 | | ||
|
||
UP027.py:6:26: UP027 [*] Replace unpacked list comprehension with a generator expression | ||
| | ||
4 | foo, bar, baz =[fn(x) for x in items] | ||
5 | | ||
6 | foo, bar, baz = [fn(x) for x in items] | ||
| ^^^^^^^^^^^^^^^^^^^^^^ UP027 | ||
7 | | ||
8 | foo, bar, baz = [[i for i in fn(x)] for x in items] | ||
| | ||
= help: Replace with generator expression | ||
|
||
ℹ Safe fix | ||
3 3 | | ||
4 4 | foo, bar, baz =[fn(x) for x in items] | ||
5 5 | | ||
6 |-foo, bar, baz = [fn(x) for x in items] | ||
6 |+foo, bar, baz = (fn(x) for x in items) | ||
7 7 | | ||
8 8 | foo, bar, baz = [[i for i in fn(x)] for x in items] | ||
9 9 | | ||
|
||
UP027.py:8:17: UP027 [*] Replace unpacked list comprehension with a generator expression | ||
| | ||
6 | foo, bar, baz = [fn(x) for x in items] | ||
7 | | ||
8 | foo, bar, baz = [[i for i in fn(x)] for x in items] | ||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ UP027 | ||
9 | | ||
10 | foo, bar, baz = [ | ||
| | ||
= help: Replace with generator expression | ||
|
||
ℹ Safe fix | ||
5 5 | | ||
6 6 | foo, bar, baz = [fn(x) for x in items] | ||
7 7 | | ||
8 |-foo, bar, baz = [[i for i in fn(x)] for x in items] | ||
8 |+foo, bar, baz = ([i for i in fn(x)] for x in items) | ||
9 9 | | ||
10 10 | foo, bar, baz = [ | ||
11 11 | fn(x) | ||
|
||
UP027.py:10:17: UP027 [*] Replace unpacked list comprehension with a generator expression | ||
| | ||
8 | foo, bar, baz = [[i for i in fn(x)] for x in items] | ||
9 | | ||
10 | foo, bar, baz = [ | ||
| _________________^ | ||
11 | | fn(x) | ||
12 | | for x in items | ||
13 | | ] | ||
| |_^ UP027 | ||
14 | | ||
15 | # Should not change | ||
| | ||
= help: Replace with generator expression | ||
|
||
ℹ Safe fix | ||
7 7 | | ||
8 8 | foo, bar, baz = [[i for i in fn(x)] for x in items] | ||
9 9 | | ||
10 |-foo, bar, baz = [ | ||
10 |+foo, bar, baz = ( | ||
11 11 | fn(x) | ||
12 12 | for x in items | ||
13 |-] | ||
13 |+) | ||
14 14 | | ||
15 15 | # Should not change | ||
16 16 | foo = [fn(x) for x in items] | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.