[Cython] Cython Modules as builtins

2015-08-12 Thread Phil Thompson
Is there any reason why cython generated modules don’t use the fully qualified name (ie. __Pyx_MODULE_NAME) in the call to Py_InitModule4() and the PyModuleDef structure? I want to statically link a module and add it to Python’s inittab but things don’t work without a fully qualified name. Than

Re: [Cython] [cython-users] Confusing error when trying to get non-existent attribute of cimported library

2015-08-12 Thread Robert Bradshaw
On Tue, Aug 11, 2015 at 9:10 PM, Antony Lee wrote: > Compiling and running > > from libc cimport math > def f(): > print(math.abs(-1)) # oops, should be fabs > > results in NameError, name 'math' is not defined. I guess that this results > from the fact that cimported names and other names ef