
The Python compiler Cython 0.11 was just released. We would like to thank Stefan Behnel, Robert Bradshaw, Ondrej Certik, Lisandro Dalcin, Jason Evans, Magnus Lie Hetland, Hoyt Koepke, and Dag Sverre Seljebotn who contributed code to this release, as well as the many others who contributed ideas, bug reports, and feedback. What is Cython? ===================== Cython is a language that makes writing C extensions for the Python language as easy as Python itself. Cython is based on the well-known Pyrex, but supports more cutting edge functionality and optimizations. The Cython language is very close to the Python language, but Cython additionally supports calling C functions and declaring C types on variables and class attributes. This allows the compiler to generate very efficient C code from Cython code. This makes Cython the ideal language for wrapping for external C libraries, and for fast C modules that speed up the execution of Python code. Where to get it? ===================== http://cython.org/ http://pypi.python.org/pypi/Cython/ Release Notes ===================== The majority of changes in this version are internal, the largest of which is moving most temp allocation to the code generation phase which has several advantages and will greatly facilitate future development. In conjunction with this, Dag Sverre Seljebotn wrote a "reference counting nanny" which, when enabled, warns of potential double-frees and memory-leaks. Though it will not find memory leaks in user code (malloc is just as dangerous as ever) it is a great tool for verifying that Cython itself is outputting correct code and is an invaluable consistency check during the many changes we've been making to temporary variable handling. There have also been many improvements for developers--for example, the parse tree is printed on compiler crashes, the testing framework has been enhanced, and there is a mode to produce output files interlaced with the compiler's call stacks to more easily trace what's going on. The most visible new user-level features are size_t as a native type (as part of Lisandro Dalcin's cleanup and improvement of Python <-> C type conversions) and proper Python semantics for optimized range() loops (Magnus Lie Hetland). C(p)def functions can now take decorators, though only @cython.locals is currently supported, and inline functions can appear in .pxd files. There were also numerious bug fixes, optimizations, and general code cleanups that happened in this release too. A list of closed tickets can be found at http://trac.cython.org/ cython_trac/query?group=component&milestone=0.11 . Though not every change is associated to a trac ticket, we plan to be more stringent about this in the future. We have several patches already done that didn't make it into 0.11, and so 0.11.1 will be out soon.
participants (1)
-
Robert Bradshaw