mirror of https://github.com/python/cpython
make PyImport_ImportModuleLevel's first arg const like similiar functions (closes #12173)
This commit is contained in:
parent
8a021009ea
commit
04778a8150
|
@ -44,7 +44,7 @@ PyAPI_FUNC(PyObject *) PyImport_ImportModuleNoBlock(
|
||||||
const char *name /* UTF-8 encoded string */
|
const char *name /* UTF-8 encoded string */
|
||||||
);
|
);
|
||||||
PyAPI_FUNC(PyObject *) PyImport_ImportModuleLevel(
|
PyAPI_FUNC(PyObject *) PyImport_ImportModuleLevel(
|
||||||
char *name, /* UTF-8 encoded string */
|
const char *name, /* UTF-8 encoded string */
|
||||||
PyObject *globals,
|
PyObject *globals,
|
||||||
PyObject *locals,
|
PyObject *locals,
|
||||||
PyObject *fromlist,
|
PyObject *fromlist,
|
||||||
|
|
|
@ -826,6 +826,9 @@ C-API
|
||||||
- PY_PATCHLEVEL_REVISION has been removed, since it's meaningless with
|
- PY_PATCHLEVEL_REVISION has been removed, since it's meaningless with
|
||||||
Mercurial.
|
Mercurial.
|
||||||
|
|
||||||
|
- Issue #12173: The first argument of PyImport_ImportModuleLevel is now `const
|
||||||
|
char *` instead of `char *1`.
|
||||||
|
|
||||||
Documentation
|
Documentation
|
||||||
-------------
|
-------------
|
||||||
|
|
||||||
|
|
|
@ -2818,7 +2818,7 @@ PyImport_ImportModuleLevelObject(PyObject *name, PyObject *globals,
|
||||||
}
|
}
|
||||||
|
|
||||||
PyObject *
|
PyObject *
|
||||||
PyImport_ImportModuleLevel(char *name, PyObject *globals, PyObject *locals,
|
PyImport_ImportModuleLevel(const char *name, PyObject *globals, PyObject *locals,
|
||||||
PyObject *fromlist, int level)
|
PyObject *fromlist, int level)
|
||||||
{
|
{
|
||||||
PyObject *nameobj, *mod;
|
PyObject *nameobj, *mod;
|
||||||
|
|
Loading…
Reference in New Issue