mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
gh-107211: Rename PySymtable_Lookup() to _PySymtable_Lookup() (#107212)
Rename the internal PySymtable_Lookup() function to _PySymtable_Lookup() and no longer export it.
This commit is contained in:
parent
4bbf071635
commit
2e0744955f
3 changed files with 4 additions and 4 deletions
|
@ -101,7 +101,7 @@ extern struct symtable* _PySymtable_Build(
|
||||||
struct _mod *mod,
|
struct _mod *mod,
|
||||||
PyObject *filename,
|
PyObject *filename,
|
||||||
PyFutureFeatures *future);
|
PyFutureFeatures *future);
|
||||||
PyAPI_FUNC(PySTEntryObject *) PySymtable_Lookup(struct symtable *, void *);
|
extern PySTEntryObject* _PySymtable_Lookup(struct symtable *, void *);
|
||||||
|
|
||||||
extern void _PySymtable_Free(struct symtable *);
|
extern void _PySymtable_Free(struct symtable *);
|
||||||
|
|
||||||
|
|
|
@ -1280,7 +1280,7 @@ compiler_enter_scope(struct compiler *c, identifier name,
|
||||||
u->u_metadata.u_argcount = 0;
|
u->u_metadata.u_argcount = 0;
|
||||||
u->u_metadata.u_posonlyargcount = 0;
|
u->u_metadata.u_posonlyargcount = 0;
|
||||||
u->u_metadata.u_kwonlyargcount = 0;
|
u->u_metadata.u_kwonlyargcount = 0;
|
||||||
u->u_ste = PySymtable_Lookup(c->c_st, key);
|
u->u_ste = _PySymtable_Lookup(c->c_st, key);
|
||||||
if (!u->u_ste) {
|
if (!u->u_ste) {
|
||||||
compiler_unit_free(u);
|
compiler_unit_free(u);
|
||||||
return ERROR;
|
return ERROR;
|
||||||
|
@ -5685,7 +5685,7 @@ compiler_comprehension(struct compiler *c, expr_ty e, int type,
|
||||||
comprehension_ty outermost;
|
comprehension_ty outermost;
|
||||||
int scope_type = c->u->u_scope_type;
|
int scope_type = c->u->u_scope_type;
|
||||||
int is_top_level_await = IS_TOP_LEVEL_AWAIT(c);
|
int is_top_level_await = IS_TOP_LEVEL_AWAIT(c);
|
||||||
PySTEntryObject *entry = PySymtable_Lookup(c->c_st, (void *)e);
|
PySTEntryObject *entry = _PySymtable_Lookup(c->c_st, (void *)e);
|
||||||
if (entry == NULL) {
|
if (entry == NULL) {
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
|
@ -389,7 +389,7 @@ _PySymtable_Free(struct symtable *st)
|
||||||
}
|
}
|
||||||
|
|
||||||
PySTEntryObject *
|
PySTEntryObject *
|
||||||
PySymtable_Lookup(struct symtable *st, void *key)
|
_PySymtable_Lookup(struct symtable *st, void *key)
|
||||||
{
|
{
|
||||||
PyObject *k, *v;
|
PyObject *k, *v;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue