Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix InterpreterID intialization.
  • Loading branch information
ericsnowcurrently committed Mar 1, 2019
commit 582e52043f89393b6e11e99bab7bd4a86adf4ec3
1 change: 1 addition & 0 deletions Makefile.pre.in
Original file line number Diff line number Diff line change
Expand Up @@ -1010,6 +1010,7 @@ PYTHON_HEADERS= \
$(srcdir)/Include/funcobject.h \
$(srcdir)/Include/genobject.h \
$(srcdir)/Include/import.h \
$(srcdir)/Include//interpreteridobject.h \
$(srcdir)/Include/intrcheck.h \
$(srcdir)/Include/iterobject.h \
$(srcdir)/Include/listobject.h \
Expand Down
2 changes: 1 addition & 1 deletion Objects/interpreteridobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ PyDoc_STRVAR(interpid_doc,

PyTypeObject _PyInterpreterID_Type = {
PyVarObject_HEAD_INIT(&PyType_Type, 0)
"interpreters.InterpreterID", /* tp_name */
"InterpreterID", /* tp_name */
sizeof(interpid), /* tp_basicsize */
0, /* tp_itemsize */
(destructor)interpid_dealloc, /* tp_dealloc */
Expand Down
2 changes: 2 additions & 0 deletions Objects/object.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include "pycore_pystate.h"
#include "pycore_context.h"
#include "frameobject.h"
#include "interpreteridobject.h"

#ifdef __cplusplus
extern "C" {
Expand Down Expand Up @@ -1806,6 +1807,7 @@ _PyTypes_Init(void)
INIT_TYPE(&PySeqIter_Type, "sequence iterator");
INIT_TYPE(&PyCoro_Type, "coroutine");
INIT_TYPE(&_PyCoroWrapper_Type, "coroutine wrapper");
INIT_TYPE(&_PyInterpreterID_Type, "interpreter ID");
return _Py_INIT_OK();

#undef INIT_TYPE
Expand Down
4 changes: 1 addition & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -784,9 +784,7 @@ def detect_simple_extensions(self):
self.add(Extension('syslog', ['syslogmodule.c']))

# Python interface to subinterpreter C-API.
self.add(Extension('_xxsubinterpreters',
['_xxsubinterpretersmodule.c'],
define_macros=[('Py_BUILD_CORE', '')]))
self.add(Extension('_xxsubinterpreters', ['_xxsubinterpretersmodule.c']))

#
# Here ends the simple stuff. From here on, modules need certain
Expand Down