mirror of
https://github.com/python/cpython.git
synced 2025-12-08 06:10:17 +00:00
Regen stuff
This commit is contained in:
parent
db151a5192
commit
ea120fc6e9
17 changed files with 26 additions and 33 deletions
|
|
@ -311,7 +311,7 @@ PyAPI_FUNC(void) _PyEval_FormatExcCheckArg(PyThreadState *tstate, PyObject *exc,
|
|||
PyAPI_FUNC(void) _PyEval_FormatExcUnbound(PyThreadState *tstate, PyCodeObject *co, int oparg);
|
||||
PyAPI_FUNC(void) _PyEval_FormatKwargsError(PyThreadState *tstate, PyObject *func, PyObject *kwargs);
|
||||
PyAPI_FUNC(PyObject *) _PyEval_ImportFrom(PyThreadState *, PyObject *, PyObject *);
|
||||
PyAPI_FUNC(PyObject *) _PyEval_LazyImportName(PyThreadState *tstate, PyObject *builtins, PyObject *globals,
|
||||
PyAPI_FUNC(PyObject *) _PyEval_LazyImportName(PyThreadState *tstate, PyObject *builtins, PyObject *globals,
|
||||
PyObject *locals, PyObject *name, PyObject *fromlist, PyObject *level, int lazy);
|
||||
PyAPI_FUNC(PyObject *) _PyEval_LazyImportFrom(PyThreadState *tstate, PyObject *v, PyObject *name);
|
||||
PyAPI_FUNC(PyObject *) _PyEval_ImportName(PyThreadState *tstate, PyObject *builtins, PyObject *globals, PyObject *locals,
|
||||
|
|
|
|||
|
|
@ -1706,7 +1706,6 @@ _PyStaticObjects_CheckRefcnt(PyInterpreterState *interp) {
|
|||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(effective_ids));
|
||||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(element_factory));
|
||||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(emptyerror));
|
||||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(enabled));
|
||||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(encode));
|
||||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(encoding));
|
||||
_PyStaticObject_CheckRefcnt((PyObject *)&_Py_ID(end));
|
||||
|
|
|
|||
|
|
@ -429,7 +429,6 @@ struct _Py_global_strings {
|
|||
STRUCT_FOR_ID(effective_ids)
|
||||
STRUCT_FOR_ID(element_factory)
|
||||
STRUCT_FOR_ID(emptyerror)
|
||||
STRUCT_FOR_ID(enabled)
|
||||
STRUCT_FOR_ID(encode)
|
||||
STRUCT_FOR_ID(encoding)
|
||||
STRUCT_FOR_ID(end)
|
||||
|
|
|
|||
1
Include/internal/pycore_runtime_init_generated.h
generated
1
Include/internal/pycore_runtime_init_generated.h
generated
|
|
@ -1704,7 +1704,6 @@ extern "C" {
|
|||
INIT_ID(effective_ids), \
|
||||
INIT_ID(element_factory), \
|
||||
INIT_ID(emptyerror), \
|
||||
INIT_ID(enabled), \
|
||||
INIT_ID(encode), \
|
||||
INIT_ID(encoding), \
|
||||
INIT_ID(end), \
|
||||
|
|
|
|||
|
|
@ -1496,10 +1496,6 @@ _PyUnicode_InitStaticStrings(PyInterpreterState *interp) {
|
|||
_PyUnicode_InternStatic(interp, &string);
|
||||
assert(_PyUnicode_CheckConsistency(string, 1));
|
||||
assert(PyUnicode_GET_LENGTH(string) != 1);
|
||||
string = &_Py_ID(enabled);
|
||||
_PyUnicode_InternStatic(interp, &string);
|
||||
assert(_PyUnicode_CheckConsistency(string, 1));
|
||||
assert(PyUnicode_GET_LENGTH(string) != 1);
|
||||
string = &_Py_ID(encode);
|
||||
_PyUnicode_InternStatic(interp, &string);
|
||||
assert(_PyUnicode_CheckConsistency(string, 1));
|
||||
|
|
|
|||
|
|
@ -191,7 +191,7 @@ def attr_matches(self, text):
|
|||
continue
|
||||
|
||||
if (isinstance(thisobject, types.ModuleType)
|
||||
and
|
||||
and
|
||||
isinstance(thisobject.__dict__.get(word),types.LazyImportType)
|
||||
):
|
||||
value = thisobject.__dict__.get(word)
|
||||
|
|
|
|||
|
|
@ -1,3 +1,2 @@
|
|||
def foo():
|
||||
return 'foo'
|
||||
|
||||
|
|
|
|||
|
|
@ -1,2 +1 @@
|
|||
def f(): pass
|
||||
|
||||
|
|
|
|||
12
Programs/test_frozenmain.h
generated
12
Programs/test_frozenmain.h
generated
|
|
@ -13,10 +13,10 @@ unsigned char M_test_frozenmain[] = {
|
|||
82,5,93,6,12,0,82,6,93,5,93,6,44,26,0,0,
|
||||
0,0,0,0,0,0,0,0,12,0,50,4,52,1,0,0,
|
||||
0,0,0,0,31,0,75,26,0,0,9,0,30,0,82,1,
|
||||
35,0,41,8,233,0,0,0,0,78,122,18,70,114,111,122,
|
||||
101,110,32,72,101,108,108,111,32,87,111,114,108,100,122,8,
|
||||
35,0,41,8,233,0,0,0,0,78,218,18,70,114,111,122,
|
||||
101,110,32,72,101,108,108,111,32,87,111,114,108,100,218,8,
|
||||
115,121,115,46,97,114,103,118,218,6,99,111,110,102,105,103,
|
||||
122,7,99,111,110,102,105,103,32,122,2,58,32,41,5,218,
|
||||
218,7,99,111,110,102,105,103,32,218,2,58,32,41,5,218,
|
||||
12,112,114,111,103,114,97,109,95,110,97,109,101,218,10,101,
|
||||
120,101,99,117,116,97,98,108,101,218,15,117,115,101,95,101,
|
||||
110,118,105,114,111,110,109,101,110,116,218,17,99,111,110,102,
|
||||
|
|
@ -25,15 +25,15 @@ unsigned char M_test_frozenmain[] = {
|
|||
3,115,121,115,218,17,95,116,101,115,116,105,110,116,101,114,
|
||||
110,97,108,99,97,112,105,218,5,112,114,105,110,116,218,4,
|
||||
97,114,103,118,218,11,103,101,116,95,99,111,110,102,105,103,
|
||||
115,114,3,0,0,0,218,3,107,101,121,169,0,243,0,0,
|
||||
115,114,5,0,0,0,218,3,107,101,121,169,0,243,0,0,
|
||||
0,0,218,18,116,101,115,116,95,102,114,111,122,101,110,109,
|
||||
97,105,110,46,112,121,218,8,60,109,111,100,117,108,101,62,
|
||||
114,18,0,0,0,1,0,0,0,115,94,0,0,0,240,3,
|
||||
114,22,0,0,0,1,0,0,0,115,94,0,0,0,240,3,
|
||||
1,1,1,243,8,0,1,11,219,0,24,225,0,5,208,6,
|
||||
26,212,0,27,217,0,5,128,106,144,35,151,40,145,40,212,
|
||||
0,27,216,9,26,215,9,38,210,9,38,211,9,40,168,24,
|
||||
213,9,50,128,6,243,2,6,12,2,128,67,241,14,0,5,
|
||||
10,136,71,144,67,144,53,152,2,152,54,160,35,157,59,152,
|
||||
45,208,10,40,214,4,41,243,15,6,12,2,114,16,0,0,
|
||||
45,208,10,40,214,4,41,243,15,6,12,2,114,20,0,0,
|
||||
0,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -297,7 +297,7 @@ __lazy_import__ as builtin___lazy_import__
|
|||
fromlist: object(c_default="NULL") = ()
|
||||
level: int = 0
|
||||
|
||||
Lazily imports a module.
|
||||
Lazily imports a module.
|
||||
|
||||
Returns either the module to be imported or a imp.lazy_module object which
|
||||
indicates the module to be lazily imported.
|
||||
|
|
|
|||
|
|
@ -3512,7 +3512,7 @@ check_lazy_import_comatibility(PyThreadState *tstate, PyObject *globals,
|
|||
|
||||
PyObject *
|
||||
_PyEval_LazyImportName(PyThreadState *tstate, PyObject *builtins, PyObject *globals,
|
||||
PyObject *locals, PyObject *name, PyObject *fromlist, PyObject *level,
|
||||
PyObject *locals, PyObject *name, PyObject *fromlist, PyObject *level,
|
||||
int lazy)
|
||||
{
|
||||
PyObject *res = NULL;
|
||||
|
|
|
|||
2
Python/clinic/bltinmodule.c.h
generated
2
Python/clinic/bltinmodule.c.h
generated
|
|
@ -1380,4 +1380,4 @@ builtin_issubclass(PyObject *module, PyObject *const *args, Py_ssize_t nargs)
|
|||
exit:
|
||||
return return_value;
|
||||
}
|
||||
/*[clinic end generated code: output=65b2a6dfb50b64bc input=a9049054013a1b77]*/
|
||||
/*[clinic end generated code: output=1c3327da8885bb8e input=a9049054013a1b77]*/
|
||||
|
|
|
|||
9
Python/clinic/sysmodule.c.h
generated
9
Python/clinic/sysmodule.c.h
generated
|
|
@ -2000,9 +2000,10 @@ PyDoc_STRVAR(sys_get_lazy_modules__doc__,
|
|||
"\n"
|
||||
"Gets the set of module names that have been lazily imported.\n"
|
||||
"\n"
|
||||
"Returns a set of fully-qualified module names that have been lazily imported\n"
|
||||
"at some point (primarily for diagnostics and introspection). Note that modules\n"
|
||||
"are removed from this set when they are reified (actually loaded).");
|
||||
"Returns a set of fully-qualified module names that have been lazily\n"
|
||||
"imported at some point (primarily for diagnostics and introspection).\n"
|
||||
"Note that modules are removed from this set when they are reified\n"
|
||||
"(actually loaded).");
|
||||
|
||||
#define SYS_GET_LAZY_MODULES_METHODDEF \
|
||||
{"get_lazy_modules", (PyCFunction)sys_get_lazy_modules, METH_NOARGS, sys_get_lazy_modules__doc__},
|
||||
|
|
@ -2143,4 +2144,4 @@ exit:
|
|||
#ifndef SYS_GETANDROIDAPILEVEL_METHODDEF
|
||||
#define SYS_GETANDROIDAPILEVEL_METHODDEF
|
||||
#endif /* !defined(SYS_GETANDROIDAPILEVEL_METHODDEF) */
|
||||
/*[clinic end generated code: output=cec3ca2ba0ad32cc input=a9049054013a1b77]*/
|
||||
/*[clinic end generated code: output=a64004ec17cceb34 input=a9049054013a1b77]*/
|
||||
|
|
|
|||
|
|
@ -2960,7 +2960,7 @@ codegen_from_import(compiler *c, stmt_ty s)
|
|||
ADDOP_NAME_CUSTOM(c, LOC(s), IMPORT_NAME, from, names, 2, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
for (Py_ssize_t i = 0; i < n; i++) {
|
||||
alias_ty alias = (alias_ty)asdl_seq_GET(s->v.ImportFrom.names, i);
|
||||
identifier store_name;
|
||||
|
|
|
|||
|
|
@ -816,7 +816,7 @@ _PyCompile_InExceptionHandler(compiler *c)
|
|||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -3793,7 +3793,7 @@ resolve_name(PyThreadState *tstate, PyObject *name, PyObject *globals, int level
|
|||
PyObject *
|
||||
_PyImport_ResolveName(PyThreadState *tstate, PyObject *name, PyObject *globals, int level)
|
||||
{
|
||||
return resolve_name(tstate, name, globals, level);
|
||||
return resolve_name(tstate, name, globals, level);
|
||||
}
|
||||
|
||||
PyObject *
|
||||
|
|
@ -4767,7 +4767,7 @@ PyImport_SetLazyImportsFilter(PyObject *filter)
|
|||
|
||||
/* Gets the lazy imports filter. Returns a new reference. */
|
||||
PyObject *
|
||||
PyImport_GetLazyImportsFilter()
|
||||
PyImport_GetLazyImportsFilter(void)
|
||||
{
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
return Py_XNewRef(FT_ATOMIC_LOAD_PTR_RELAXED(LAZY_IMPORTS_FILTER(interp)));
|
||||
|
|
@ -4784,7 +4784,7 @@ PyImport_SetLazyImportsMode(PyImport_LazyImportsMode mode)
|
|||
/* Checks if lazy imports is globally enabled or disabled. Return 1 when globally
|
||||
* forced on, 0 when globally forced off, or -1 when */
|
||||
PyImport_LazyImportsMode
|
||||
PyImport_GetLazyImportsMode()
|
||||
PyImport_GetLazyImportsMode(void)
|
||||
{
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
return FT_ATOMIC_LOAD_INT_RELAXED(LAZY_IMPORTS_MODE(interp));
|
||||
|
|
|
|||
|
|
@ -2896,15 +2896,16 @@ sys.get_lazy_modules
|
|||
|
||||
Gets the set of module names that have been lazily imported.
|
||||
|
||||
Returns a set of fully-qualified module names that have been lazily imported
|
||||
at some point (primarily for diagnostics and introspection). Note that modules
|
||||
are removed from this set when they are reified (actually loaded).
|
||||
Returns a set of fully-qualified module names that have been lazily
|
||||
imported at some point (primarily for diagnostics and introspection).
|
||||
Note that modules are removed from this set when they are reified
|
||||
(actually loaded).
|
||||
|
||||
[clinic start generated code]*/
|
||||
|
||||
static PyObject *
|
||||
sys_get_lazy_modules_impl(PyObject *module)
|
||||
/*[clinic end generated code: output=4c641f8881ba87c0 input=06c7a1d05bcfa36a]*/
|
||||
/*[clinic end generated code: output=4c641f8881ba87c0 input=511b3a9682c09282]*/
|
||||
{
|
||||
PyInterpreterState *interp = _PyInterpreterState_GET();
|
||||
PyObject *lazy_modules_set = interp->imports.lazy_modules_set;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue