[pypy-issue] [issue1703] Crash when overriding PyType_Type.tp_new

Johan Rade tracker at bugs.pypy.org
Sun Mar 9 13:28:48 CET 2014


New submission from Johan Rade <johan.rade at gmail.com>:

If you use the C-API to derive a new metaclass from PyType_Type, override the
tp_new slot, and have the overriding tp_new call PyType_Type.tp_new, then PyPy
gets into an infinite loop and crashes.

I have attached files that show the problem.

Instructions:
    Compile Foo3.c as a python extension module named Foo3.
    Set up the paths so that Test3.py can find Foo3.
    Run Test3.py

Expected behavior and observed behavior with CPython 2.7.6:
    Test3.py runs

Observed behavior with PyPy 2.2.1:
    Test3.py crashes.

Fixing this issue is probably needed to get PySide to run on PyPy using the
Python C-API.

----------
files: Foo3.zip
messages: 6584
nosy: jrade, pypy-issue
priority: bug
status: unread
title: Crash when overriding PyType_Type.tp_new

________________________________________
PyPy bug tracker <tracker at bugs.pypy.org>
<https://bugs.pypy.org/issue1703>
________________________________________


More information about the pypy-issue mailing list