bpo-40939: Remove even more references to the old parser (GH-21642)
https://github.com/python/cpython/commit/b3fbff7289176ba1a322e6899c3d4a04880... commit: b3fbff7289176ba1a322e6899c3d4a04880ed5a7 branch: master author: Lysandros Nikolaou <lisandrosnik@gmail.com> committer: GitHub <noreply@github.com> date: 2020-07-27T12:52:59-07:00 summary: bpo-40939: Remove even more references to the old parser (GH-21642) Automerge-Triggered-By: @lysnikolaou files: M Include/internal/pycore_interp.h M Makefile.pre.in M Tools/c-analyzer/TODO M Tools/c-analyzer/cpython/_generate.py M Tools/c-analyzer/known.tsv diff --git a/Include/internal/pycore_interp.h b/Include/internal/pycore_interp.h index cfc27470c8041..538aa5a653fbf 100644 --- a/Include/internal/pycore_interp.h +++ b/Include/internal/pycore_interp.h @@ -13,13 +13,6 @@ extern "C" { #include "pycore_gc.h" /* struct _gc_runtime_state */ #include "pycore_warnings.h" /* struct _warnings_runtime_state */ -struct _Py_parser_state { - struct { - int level; - int atbol; - } listnode; -}; - struct _pending_calls { PyThread_type_lock lock; /* Request for running pending calls. */ @@ -240,8 +233,6 @@ struct _is { PyObject *audit_hooks; - struct _Py_parser_state parser; - #if _PY_NSMALLNEGINTS + _PY_NSMALLPOSINTS > 0 /* Small integers are preallocated in this array so that they can be shared. diff --git a/Makefile.pre.in b/Makefile.pre.in index 3428b9842a5a0..6b8f4e086ef35 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -545,7 +545,6 @@ coverage-lcov: '*/Modules/zlib/*' \ '*/Include/*' \ '*/Modules/xx*.c' \ - '*/Parser/listnode.c' \ '*/Python/pyfpe.c' \ '*/Python/pystrcmp.c' \ '/usr/include/*' \ diff --git a/Tools/c-analyzer/TODO b/Tools/c-analyzer/TODO index 829daba291463..1134055f9a8fd 100644 --- a/Tools/c-analyzer/TODO +++ b/Tools/c-analyzer/TODO @@ -64,8 +64,6 @@ Objects/object.c:_Py_RefTotal Py_ssize_t _Py_ Objects/tupleobject.c:_Py_fast_tuple_allocs Py_ssize_t _Py_fast_tuple_allocs Objects/tupleobject.c:_Py_tuple_zero_allocs Py_ssize_t _Py_tuple_zero_allocs Objects/typeobject.c:next_version_tag static unsigned int next_version_tag -Parser/listnode.c:atbol static int atbol -Parser/listnode.c:level static int level Python/Python-ast.c:init_types():initialized static int initialized Python/bootstrap_hash.c:urandom_cache static struct { int fd; dev_t st_dev; ino_t st_ino; } urandom_cache Python/ceval.c:_Py_CheckRecursionLimit int _Py_CheckRecursionLimit diff --git a/Tools/c-analyzer/cpython/_generate.py b/Tools/c-analyzer/cpython/_generate.py index 4c340acf99e1c..3456604b81470 100644 --- a/Tools/c-analyzer/cpython/_generate.py +++ b/Tools/c-analyzer/cpython/_generate.py @@ -183,9 +183,6 @@ def find_matching_variable(varid, varcache, allfilenames, *, 'float_format': 'static float_format_type ', 'detected_double_format': 'static float_format_type ', 'detected_float_format': 'static float_format_type ', - # Parser/listnode.c - 'level': 'static int ', - 'atbol': 'static int ', # Python/dtoa.c 'private_mem': 'static double private_mem[PRIVATE_mem]', 'pmem_next': 'static double *', diff --git a/Tools/c-analyzer/known.tsv b/Tools/c-analyzer/known.tsv index db44080bc2e31..f92b45e5b4d85 100644 --- a/Tools/c-analyzer/known.tsv +++ b/Tools/c-analyzer/known.tsv @@ -51,7 +51,6 @@ Objects/genobject.c - async_gen_memberlist variable static PyMemberDef async_gen Objects/genobject.c - async_gen_methods variable static PyMethodDef async_gen_methods Python/Python-ast.c - AsyncWith_fields variable static const char *AsyncWith_fields[] Python/Python-ast.c - AsyncWith_type variable static PyTypeObject *AsyncWith_type -Parser/listnode.c - atbol variable static int atbol Modules/atexitmodule.c - atexit_methods variable static PyMethodDef atexit_methods Modules/atexitmodule.c - atexitmodule variable static struct PyModuleDef atexitmodule Modules/atexitmodule.c - atexit_slots variable static PyModuleDef_Slot atexit_slots[] @@ -429,7 +428,6 @@ Modules/_json.c encoder_call kwlist variable static const char *kwlist[] Python/symtable.c - lambda variable static identifier lambda Python/Python-ast.c - Lambda_fields variable static const char *Lambda_fields[] Python/Python-ast.c - Lambda_type variable static PyTypeObject *Lambda_type -Parser/listnode.c - level variable static int level Objects/listobject.c - list_as_mapping variable static PyMappingMethods list_as_mapping Objects/listobject.c - list_as_sequence variable static PySequenceMethods list_as_sequence Python/symtable.c - listcomp variable static identifier listcomp
participants (1)
-
Lysandros Nikolaou