[pypy-commit] pypy cpyext-injection: fix simple name errors, install pyflakes people
fijal
pypy.commits at gmail.com
Mon Oct 24 11:29:18 EDT 2016
Author: fijal
Branch: cpyext-injection
Changeset: r87917:f7bbb503eac2
Date: 2016-10-24 17:28 +0200
http://bitbucket.org/pypy/pypy/changeset/f7bbb503eac2/
Log: fix simple name errors, install pyflakes people
diff --git a/pypy/module/cpyext/__init__.py b/pypy/module/cpyext/__init__.py
--- a/pypy/module/cpyext/__init__.py
+++ b/pypy/module/cpyext/__init__.py
@@ -75,6 +75,7 @@
import pypy.module.cpyext.pytraceback
import pypy.module.cpyext.methodobject
import pypy.module.cpyext.injection._test_module
+import pypy.module.cpyext.injection.numpy
# now that all rffi_platform.Struct types are registered, configure them
api.configure_types()
diff --git a/pypy/module/cpyext/injection/numpy.py b/pypy/module/cpyext/injection/numpy.py
--- a/pypy/module/cpyext/injection/numpy.py
+++ b/pypy/module/cpyext/injection/numpy.py
@@ -38,7 +38,7 @@
w_type = org.w_float64_type
return w_type
-def mything_realize(space, obj):
+def array_realize(space, obj):
intval = rffi.cast(lltype.Signed, rffi.cast(PyArrayObject, obj).foo)
w_obj = W_ArrayObject(intval)
track_reference(space, obj, w_obj)
@@ -47,8 +47,8 @@
@bootstrap_function
def init_mything(space):
make_typedescr(W_ArrayObject.typedef,
- basestruct=mytype_object.TO,
- realize=mything_realize)
+ basestruct=PyArrayObject.TO,
+ realize=array_realize)
@unwrap_spec(index=int)
def injected_getitem(space, w_self, index):
More information about the pypy-commit
mailing list