Commit 58b4dd04 authored by Kevin Modzelewski's avatar Kevin Modzelewski Committed by Kevin Modzelewski

Get the sharedmods (ctypes, etc) building

parent 0e67e50f
......@@ -141,8 +141,8 @@ PyAPI_FUNC(void) PyGC_RegisterStaticConstantLocation(PyObject**) PYSTON_NOEXCEPT
PyAPI_FUNC(PyObject*) _PyGC_GetGarbage(void) PYSTON_NOEXCEPT;
// Pyston addition:
PyAPI_FUNC(void) PyGC_Enable() PYSTON_NOEXCEPT;
PyAPI_FUNC(void) PyGC_Disable() PYSTON_NOEXCEPT;
PyAPI_FUNC(void) PyGC_Enable(void) PYSTON_NOEXCEPT;
PyAPI_FUNC(void) PyGC_Disable(void) PYSTON_NOEXCEPT;
#ifdef __cplusplus
}
......
......@@ -159,7 +159,7 @@ get_handler_name(struct HandlerInfo *hinfo)
{
PyObject *name = hinfo->nameobj;
if (name == NULL) {
name = PyGC_AddRoot(PyString_FromString(hinfo->name));
name = PyString_FromString(hinfo->name);
hinfo->nameobj = name;
}
Py_XINCREF(name);
......@@ -1891,7 +1891,7 @@ MODULE_INITFUNC(void)
/* Add some symbolic constants to the module */
if (ErrorObject == NULL) {
ErrorObject = PyGC_AddRoot(PyErr_NewException("xml.parsers.expat.ExpatError",
ErrorObject = PyGC_RegisterStaticConstant(PyErr_NewException("xml.parsers.expat.ExpatError",
NULL, NULL));
if (ErrorObject == NULL)
return;
......
......@@ -930,8 +930,9 @@ setup_readline(void)
strdup(" \t\n`~!@#$%^&*()-=+[{]}\\|;:'\",<>/?");
/* All nonalphanums except '.' */
begidx = PyInt_FromLong(0L);
endidx = PyInt_FromLong(0L);
begidx = PyGC_RegisterStaticConstant(PyInt_FromLong(0L));
endidx = PyGC_RegisterStaticConstant(PyInt_FromLong(0L));
PyGC_RegisterStaticConstantLocation(&completer);
/* Initialize (allows .inputrc to override)
*
* XXX: A bug in the readline-2.2 library causes a memory leak
......
......@@ -4827,7 +4827,7 @@ extern "C" void Py_Finalize() noexcept {
}
for (auto p : constant_locations) {
Py_DECREF(*p);
Py_XDECREF(*p);
}
constant_locations.clear();
......
# expected: reffail
from future_builtins import hex, oct, map, zip, filter
from itertools import imap, izip, ifilter
......
# expected: reffail
import bz2
print bz2.decompress(bz2.compress("hello world"))
# expected: reffail
import curses, sys
try:
......
# expected: reffail
import grp
print grp.getgrnam("root")
# expected: reffail
import os
import pty
import subprocess
......
# expected: reffail
import termios, sys
fd = sys.stdout.fileno()
try:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment