[pypy-issue] Issue #2522: regression in multiple inheritance (pypy/pypy)

mattip issues-reply at bitbucket.org
Sat Mar 25 17:44:26 EDT 2017


New issue 2522: regression in multiple inheritance
https://bitbucket.org/pypy/pypy/issues/2522/regression-in-multiple-inheritance

mattip:

On PyPy 5.7 a class that inherits from a c-api class and a app-level class initiates the app-level class tp_new to 0x1. Numpy will call the second ``tp_bases``'s  ``tp_new``, which crashes. To reproduce, ``pip install numpy`` then run

```
#!python

import numpy as np
class A(object):
    pass
class B(A, np.float64):
    pass

class B0(np.float64, A):
    pass
class C0(B0):
    pass

x = B0(1.0)

```
Reported by Gelin Yan on pypy-dev, then distilled from ``numpy/core/tests/test_scalarinherit.py``




More information about the pypy-issue mailing list