diff options
author | Pablo Galindo <Pablogsal@gmail.com> | 2020-04-01 23:47:39 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-01 23:47:39 (GMT) |
commit | 168660b547d5f683c5d3c60447cfa8c6d620efc3 (patch) | |
tree | e57909715a435ccb1699af5670b3a3319636317e /Include/Python-ast.h | |
parent | 65a796e5272f61b42792d3a8c69686558c1872c5 (diff) | |
download | cpython-168660b547d5f683c5d3c60447cfa8c6d620efc3.zip cpython-168660b547d5f683c5d3c60447cfa8c6d620efc3.tar.gz cpython-168660b547d5f683c5d3c60447cfa8c6d620efc3.tar.bz2 |
bpo-40141: Add line and column information to ast.keyword nodes (GH-19283)
Diffstat (limited to 'Include/Python-ast.h')
-rw-r--r-- | Include/Python-ast.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Include/Python-ast.h b/Include/Python-ast.h index 7db0037..e7afa1e 100644 --- a/Include/Python-ast.h +++ b/Include/Python-ast.h @@ -427,6 +427,10 @@ struct _arg { struct _keyword { identifier arg; expr_ty value; + int lineno; + int col_offset; + int end_lineno; + int end_col_offset; }; struct _alias { @@ -670,8 +674,10 @@ arguments_ty _Py_arguments(asdl_seq * posonlyargs, asdl_seq * args, arg_ty arg_ty _Py_arg(identifier arg, expr_ty annotation, string type_comment, int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena *arena); -#define keyword(a0, a1, a2) _Py_keyword(a0, a1, a2) -keyword_ty _Py_keyword(identifier arg, expr_ty value, PyArena *arena); +#define keyword(a0, a1, a2, a3, a4, a5, a6) _Py_keyword(a0, a1, a2, a3, a4, a5, a6) +keyword_ty _Py_keyword(identifier arg, expr_ty value, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena + *arena); #define alias(a0, a1, a2) _Py_alias(a0, a1, a2) alias_ty _Py_alias(identifier name, identifier asname, PyArena *arena); #define withitem(a0, a1, a2) _Py_withitem(a0, a1, a2) |