Author: Richard Plangger <[email protected]>
Branch: cpyext-injection
Changeset: r87889:0a239eaad670
Date: 2016-10-20 11:58 +0200
http://bitbucket.org/pypy/pypy/changeset/0a239eaad670/

Log:    (arigato, plan_rich) add a base class to the c version of mything

diff --git a/pypy/module/cpyext/injection/_test_module.py 
b/pypy/module/cpyext/injection/_test_module.py
--- a/pypy/module/cpyext/injection/_test_module.py
+++ b/pypy/module/cpyext/injection/_test_module.py
@@ -10,7 +10,7 @@
 
 mytype_object = lltype.Ptr(lltype.Struct(
     'mytype_object',
-    *(PyObjectFields + (("foo", rffi.INT),))))
+    *(PyObjectFields + (("foo", rffi.LONG),))))
 
 
 class Original:
diff --git a/pypy/module/cpyext/test/injection.c 
b/pypy/module/cpyext/test/injection.c
--- a/pypy/module/cpyext/test/injection.c
+++ b/pypy/module/cpyext/test/injection.c
@@ -2,7 +2,7 @@
 
 typedef struct {
     PyObject_HEAD
-    int foo;
+    long foo;
 } mytype_object;
 
 
@@ -59,7 +59,7 @@
     0,                       /*tp_methods*/
     0,                       /*tp_members*/
     0,                       /*tp_getset*/
-    0,                                          /* tp_base */
+    &PyInt_Type,                                /* tp_base */
     0,                                          /* tp_dict */
     0,                                          /* tp_descr_get */
     0,                                          /* tp_descr_set */
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to