Skip to content

Commit

Permalink
pythongh-106145: Make end_{lineno,col_offset} required on `type_par…
Browse files Browse the repository at this point in the history
…am` nodes (python#106224)
  • Loading branch information
sobolevn authored and manosriram committed Jul 1, 2023
1 parent 6bf767b commit ea9c4ff
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Lib/test/test_unparse.py
Expand Up @@ -705,7 +705,7 @@ class DirectoryTestCase(ASTTestCase):
test_directories = (lib_dir, lib_dir / "test")
run_always_files = {"test_grammar.py", "test_syntax.py", "test_compile.py",
"test_ast.py", "test_asdl_parser.py", "test_fstring.py",
"test_patma.py"}
"test_patma.py", "test_type_alias.py", "test_type_params.py"}

_files_to_test = None

Expand Down
@@ -0,0 +1,2 @@
Make ``end_lineno`` and ``end_col_offset`` required on ``type_param`` ast
nodes.
2 changes: 1 addition & 1 deletion Parser/Python.asdl
Expand Up @@ -148,5 +148,5 @@ module Python
type_param = TypeVar(identifier name, expr? bound)
| ParamSpec(identifier name)
| TypeVarTuple(identifier name)
attributes (int lineno, int col_offset, int? end_lineno, int? end_col_offset)
attributes (int lineno, int col_offset, int end_lineno, int end_col_offset)
}
18 changes: 6 additions & 12 deletions Python/Python-ast.c

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit ea9c4ff

Please sign in to comment.