Cython: Difference between revisions

Content deleted Content added
m Bot: http → https
Undid revision 1291359507 by 142.186.45.76 (talk)
Line 1:
{{Distinguish|CPython}}
{{Use dmy dates|date=February 2014}}
{{short description|Programming language}}[[FreeBSD Ports]]
{{Infobox programming language
| name = Cython
| logo = Cython logo.svg
Line 18 ⟶ 19:
Cython is a [[compiled language]] that is typically used to generate [[CPython]] extension modules. Annotated Python-like code is compiled to C and then automatically [[wrapper library|wrapped in interface code]], producing extension modules that can be loaded and used by regular Python code using the import statement, but with significantly less computational overhead at [[Run time (program lifecycle phase)|run time]]. Cython also facilitates wrapping independent C or C++ code into python-importable modules.
 
Cython is written in Python and C and works on [[Microsoft Windows|Windows]], [[macOS]], and [[Linux]], and [[FreeBSD]] producing C source files compatible with CPython 2.6, 2.7, and 3.3 and later versions. The Cython source code that Cython compiles (to C) can use both Python 2 and Python 3 syntax, defaulting to Python 2 syntax in Cython 0.x and Python 3 syntax in Cython 3.x. The default can be overridden (e.g. in source code comment) to Python 3 (or 2) syntax. Since Python 3 syntax has changed in recent versions, Cython may not be up to date with the latest additions. Cython has "native support for most of the C++ language" and "compiles almost all existing Python code".<ref>{{Cite web |title=FAQ · cython/cython Wiki |url=https://github.com/cython/cython |access-date=11 January 2023 |website=GitHub |language=en}}</ref>
 
Cython 3.0.0 was released on 17 July 2023.<ref>{{Cite web |title=Cython Changelog |url=https://cython.readthedocs.io/en/latest/src/changes.html |access-date=21 July 2023 |website=cython.org |language=en}}</ref>