Cython: Difference between revisions

Content deleted Content added
It's a compiler, it generates C
reverting one edit which resulted in an incorrect first sentence
Line 27:
}}
 
The '''Cython''' [[programming language]] basedis a superset onof [[Python (programming language)|Python]], and aiming to become a superset thereof. It provides extra syntax for optional [[static type]] declarations, andwith a [[foreign function interface]] for invoking [[C (programming language)|C]]/[[C++]] [[subroutine|routines]]. Cythonand isthe aability compiledto languagedeclare thatthe generates[[static CPythontype]] extensionof modulesroutine parameters, whichlocal canvariables, thensubroutine beresults, usedand byclass regular Python codeattributes.<ref>http://docs.cython.org/src/quickstart/overview.html</ref>
 
== Overview ==
There are two major use cases for Cython: accelerate Python modules, and wrap C/C++.
Cython is a compiled language that generates CPython extension modules. These extension modules can then be loaded and used by regular Python code using the import statement. Cython is written in Python and works on [[Microsoft Windows|Windows]], [[Linux]], and [[Mac OS X]], producing source files compatible with Python 2.4 through 3.3.
 
There exists only one implementation, equally called Cython. It is a compiler written in Python that translates Cython to C. It works under [[Microsoft Windows|Windows]], [[Linux]], and [[Mac OS X]], producing modules compatible with Python 2.4 through 3.3.
 
== Hello World ==