Skip to content

Commit bcb7781

Browse files
committed
Update Python inlined files: Update to CPython 3.7.3
2 parents 67cfbcd + 572f9d4 commit bcb7781

File tree

481 files changed

+16429
-4709
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

481 files changed

+16429
-4709
lines changed

graalpython/com.oracle.graal.python.cext/include/ceval.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,12 @@ PyAPI_FUNC(PyObject *) PyEval_GetGlobals(void);
5353
PyAPI_FUNC(PyObject *) PyEval_GetLocals(void);
5454
PyAPI_FUNC(struct _frame *) PyEval_GetFrame(void);
5555

56+
#ifndef Py_LIMITED_API
57+
/* Helper to look up a builtin object */
58+
PyAPI_FUNC(PyObject *) _PyEval_GetBuiltinId(_Py_Identifier *);
5659
/* Look at the current frame's (if any) code's co_flags, and turn on
5760
the corresponding compiler flags in cf->cf_flags. Return 1 if any
5861
flag was set, else return 0. */
59-
#ifndef Py_LIMITED_API
6062
PyAPI_FUNC(int) PyEval_MergeCompilerFlags(PyCompilerFlags *cf);
6163
#endif
6264

graalpython/com.oracle.graal.python.cext/include/import.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,6 @@ PyAPI_FUNC(PyObject *) PyImport_AddModuleObject(
6363
PyObject *name
6464
);
6565
#endif
66-
#ifndef Py_LIMITED_API
67-
PyAPI_FUNC(PyObject *) _PyImport_AddModuleObject(PyObject *, PyObject *);
68-
#endif
6966
PyAPI_FUNC(PyObject *) PyImport_AddModule(
7067
const char *name /* UTF-8 encoded string */
7168
);

graalpython/com.oracle.graal.python.cext/include/object.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -526,6 +526,7 @@ struct _Py_Identifier;
526526
PyAPI_FUNC(int) PyObject_Print(PyObject *, FILE *, int);
527527
PyAPI_FUNC(void) _Py_BreakPoint(void);
528528
PyAPI_FUNC(void) _PyObject_Dump(PyObject *);
529+
PyAPI_FUNC(int) _PyObject_IsFreed(PyObject *);
529530
#endif
530531
PyAPI_FUNC(PyObject *) PyObject_Repr(PyObject *);
531532
PyAPI_FUNC(PyObject *) PyObject_Str(PyObject *);

graalpython/com.oracle.graal.python.cext/include/patchlevel.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,12 @@
2323
/*--start constants--*/
2424
#define PY_MAJOR_VERSION 3
2525
#define PY_MINOR_VERSION 7
26-
#define PY_MICRO_VERSION 0
26+
#define PY_MICRO_VERSION 3
2727
#define PY_RELEASE_LEVEL PY_RELEASE_LEVEL_FINAL
2828
#define PY_RELEASE_SERIAL 0
2929

3030
/* Version as a string */
31-
#define PY_VERSION "3.7.0"
31+
#define PY_VERSION "3.7.3"
3232
/*--end constants--*/
3333

3434
/* Version as a single 4-byte hex number, e.g. 0x010502B2 == 1.5.2b2.

graalpython/com.oracle.graal.python.cext/include/pyerrors.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,9 +99,9 @@ PyAPI_FUNC(void) PyErr_SetExcInfo(PyObject *, PyObject *, PyObject *);
9999
#endif
100100

101101
#if defined(__clang__) || \
102-
(defined(__GNUC_MAJOR__) && \
103-
((__GNUC_MAJOR__ >= 3) || \
104-
(__GNUC_MAJOR__ == 2) && (__GNUC_MINOR__ >= 5)))
102+
(defined(__GNUC__) && \
103+
((__GNUC__ >= 3) || \
104+
(__GNUC__ == 2) && (__GNUC_MINOR__ >= 5)))
105105
#define _Py_NO_RETURN __attribute__((__noreturn__))
106106
#else
107107
#define _Py_NO_RETURN

graalpython/com.oracle.graal.python.cext/include/pylifecycle.h

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,21 +49,36 @@ PyAPI_FUNC(void) Py_SetPythonHome(const wchar_t *);
4949
PyAPI_FUNC(wchar_t *) Py_GetPythonHome(void);
5050

5151
#ifndef Py_LIMITED_API
52+
PyAPI_FUNC(void) _Py_SetProgramFullPath(const wchar_t *);
53+
5254
/* Only used by applications that embed the interpreter and need to
5355
* override the standard encoding determination mechanism
5456
*/
5557
PyAPI_FUNC(int) Py_SetStandardStreamEncoding(const char *encoding,
5658
const char *errors);
5759

5860
/* PEP 432 Multi-phase initialization API (Private while provisional!) */
59-
PyAPI_FUNC(_PyInitError) _Py_InitializeCore(const _PyCoreConfig *);
61+
PyAPI_FUNC(_PyInitError) _Py_InitializeCore(
62+
PyInterpreterState **interp_p,
63+
const _PyCoreConfig *config);
6064
PyAPI_FUNC(int) _Py_IsCoreInitialized(void);
65+
PyAPI_FUNC(_PyInitError) _Py_InitializeFromConfig(
66+
const _PyCoreConfig *config);
67+
#ifdef Py_BUILD_CORE
68+
PyAPI_FUNC(void) _Py_Initialize_ReadEnvVarsNoAlloc(void);
69+
#endif
70+
71+
PyAPI_FUNC(PyObject *) _Py_GetGlobalVariablesAsDict(void);
6172

6273
PyAPI_FUNC(_PyInitError) _PyCoreConfig_Read(_PyCoreConfig *);
6374
PyAPI_FUNC(void) _PyCoreConfig_Clear(_PyCoreConfig *);
6475
PyAPI_FUNC(int) _PyCoreConfig_Copy(
6576
_PyCoreConfig *config,
6677
const _PyCoreConfig *config2);
78+
PyAPI_FUNC(PyObject *) _PyCoreConfig_AsDict(const _PyCoreConfig *config);
79+
PyAPI_FUNC(void) _PyCoreConfig_SetGlobalConfig(
80+
const _PyCoreConfig *config);
81+
6782

6883
PyAPI_FUNC(_PyInitError) _PyMainInterpreterConfig_Read(
6984
_PyMainInterpreterConfig *config,
@@ -72,19 +87,26 @@ PyAPI_FUNC(void) _PyMainInterpreterConfig_Clear(_PyMainInterpreterConfig *);
7287
PyAPI_FUNC(int) _PyMainInterpreterConfig_Copy(
7388
_PyMainInterpreterConfig *config,
7489
const _PyMainInterpreterConfig *config2);
90+
/* Used by _testcapi.get_main_config() */
91+
PyAPI_FUNC(PyObject*) _PyMainInterpreterConfig_AsDict(
92+
const _PyMainInterpreterConfig *config);
93+
94+
PyAPI_FUNC(_PyInitError) _Py_InitializeMainInterpreter(
95+
PyInterpreterState *interp,
96+
const _PyMainInterpreterConfig *config);
97+
#endif /* !defined(Py_LIMITED_API) */
7598

76-
PyAPI_FUNC(_PyInitError) _Py_InitializeMainInterpreter(const _PyMainInterpreterConfig *);
77-
#endif
7899

79100
/* Initialization and finalization */
80101
PyAPI_FUNC(void) Py_Initialize(void);
81102
PyAPI_FUNC(void) Py_InitializeEx(int);
82103
#ifndef Py_LIMITED_API
83-
PyAPI_FUNC(_PyInitError) _Py_InitializeEx_Private(int, int);
84104
PyAPI_FUNC(void) _Py_FatalInitError(_PyInitError err) _Py_NO_RETURN;
85105
#endif
86106
PyAPI_FUNC(void) Py_Finalize(void);
107+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03060000
87108
PyAPI_FUNC(int) Py_FinalizeEx(void);
109+
#endif
88110
PyAPI_FUNC(int) Py_IsInitialized(void);
89111

90112
/* Subinterpreter support */

graalpython/com.oracle.graal.python.cext/include/pymem.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,9 @@ PyAPI_FUNC(int) PyTraceMalloc_Untrack(
6060
PyAPI_FUNC(PyObject*) _PyTraceMalloc_GetTraceback(
6161
unsigned int domain,
6262
uintptr_t ptr);
63-
#endif /* !Py_LIMITED_API */
63+
64+
PyAPI_FUNC(int) _PyMem_IsFreed(void *ptr, size_t size);
65+
#endif /* !defined(Py_LIMITED_API) */
6466

6567

6668
/* BEWARE:

graalpython/com.oracle.graal.python.cext/include/pystate.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,11 @@ typedef struct {
8484
#define _PyCoreConfig_INIT \
8585
(_PyCoreConfig){ \
8686
.install_signal_handlers = -1, \
87+
.ignore_environment = -1, \
8788
.use_hash_seed = -1, \
8889
.coerce_c_locale = -1, \
90+
.faulthandler = -1, \
91+
.tracemalloc = -1, \
8992
.utf8_mode = -1, \
9093
.argc = -1, \
9194
.nmodule_search_path = -1}

graalpython/com.oracle.graal.python.cext/include/sysmodule.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
*
44
* Licensed under the PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2
55
*/
6+
67
/* System module interface */
78

89
#ifndef Py_SYSMODULE_H
@@ -41,7 +42,12 @@ PyAPI_FUNC(PyObject *) PySys_GetXOptions(void);
4142
PyAPI_FUNC(size_t) _PySys_GetSizeOf(PyObject *);
4243
#endif
4344

45+
#ifdef Py_BUILD_CORE
46+
PyAPI_FUNC(int) _PySys_AddXOptionWithError(const wchar_t *s);
47+
PyAPI_FUNC(int) _PySys_AddWarnOptionWithError(PyObject *option);
48+
#endif
49+
4450
#ifdef __cplusplus
4551
}
4652
#endif
47-
#endif /* !Py_SYSMODULE_H */
53+
#endif /* !Py_SYSMODULE_H */

graalpython/com.oracle.graal.python.cext/include/typeslots.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,4 +87,4 @@
8787
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000
8888
/* New in 3.5 */
8989
#define Py_tp_finalize 80
90-
#endif
90+
#endif

0 commit comments

Comments
 (0)