We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7297f31 commit fa3bd56Copy full SHA for fa3bd56
doc/source/conf.py
@@ -52,8 +52,12 @@ class PyTypeObject(ctypes.Structure):
52
]:
53
typ = getattr(numpy, name)
54
c_typ = PyTypeObject.from_address(id(typ))
55
- c_typ.tp_name = _name_cache[typ] = b"numpy." + name.encode('utf8')
56
-
+ if sys.implementation.name == 'cpython':
+ c_typ.tp_name = _name_cache[typ] = b"numpy." + name.encode('utf8')
57
+ else:
58
+ # It is not guarenteed that the c_typ has this model on other
59
+ # implementations
60
+ _name_cache[typ] = b"numpy." + name.encode('utf8')
61
62
replace_scalar_type_names()
63
0 commit comments