Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Order merged_in utility code (#5282) | da-woods | 2023-03-01 | 1 | -2/+3 |
| | | | | | | Force utility code to come before pxd code which comes before module code. This specifically fixes #5269, (where the "ToPy" functions for cpdef enums weren't availbale when cyfunctions were created). But I think it's a good idea anyway. | ||||
* | Allow C code assertions in tests by defining regular expressions in module ↵ | scoder | 2022-07-30 | 1 | -6/+9 |
| | | | | directives. (GH-4938) | ||||
* | Minor code simplification. | Stefan Behnel | 2022-01-06 | 1 | -4/+1 |
| | |||||
* | Avoid some useless overhead in "inject_utility_code_stage". | Stefan Behnel | 2022-01-06 | 1 | -22/+27 |
| | |||||
* | Revert "Avoid some useless overhead in "inject_utility_code_stage"." | Stefan Behnel | 2022-01-06 | 1 | -25/+21 |
| | | | | This reverts commit e9435cd92d3a060c1a204f57b9ee2ebb3a46988c. | ||||
* | Avoid some useless overhead in "inject_utility_code_stage". | Stefan Behnel | 2022-01-05 | 1 | -21/+25 |
| | |||||
* | Simplify some code. | Stefan Behnel | 2022-01-04 | 1 | -5/+3 |
| | |||||
* | Avoid unnecessary directives tracking in the WithTransform since it does not ↵ | Stefan Behnel | 2022-01-03 | 1 | -1/+1 |
| | | | | need it. | ||||
* | Print pipeline timings after test runs. | Stefan Behnel | 2022-01-01 | 1 | -16/+45 |
| | |||||
* | Use thread-local storage for the global Errors state to allow threaded ↵ | scoder | 2021-12-20 | 1 | -2/+2 |
| | | | | | | | | | builds. (GH-4507) Distutils uses threading internally. Also silence some warnings about redefined classes and function signatures when setting up the builtin scope. This is at most a second-best solution since we may not notice legitimate bugs on our side this way. Better make sure we have good test coverage of builtins and related optimisations. Closes https://github.com/cython/cython/issues/4503 | ||||
* | Add directive "cpp_locals" to handle C++ variables using std::optional (GH-4225) | da-woods | 2021-06-29 | 1 | -1/+2 |
| | | | | | This avoids the need for default constructors of stack allocated variables and temps by allowing late initialisation. Closes https://github.com/cython/cython/issues/4160 | ||||
* | Execute AlignFunctionDefinitions before MarkClosureTransform. (GH-4127) | Matus Valo | 2021-05-11 | 1 | -3/+4 |
| | | | | This commit fixes a crash of Cython when generator expressions are used in cdef functions in pure python mode. Closes https://github.com/cython/cython/issues/3477 | ||||
* | Fix some issues with duplicated utilitycode (GH-3743) | da-woods | 2021-03-27 | 1 | -2/+16 |
| | | | | | | | | | * Avoid UtilityCode from cimport_from_pyx files * Unique names for generated cfunc wrappers, avoid pxd pickle code * Set .in_pxd on nodes prior to analyse_declarations Fixes #3716 Fixes #3741 Fixes #3734 | ||||
* | Fix many indentation and whitespace issues throughout the code base (GH-3673) | scoder | 2020-06-10 | 1 | -1/+1 |
| | | | … and enforce them with pycodestyle. | ||||
* | Ensure utility code keeps the directives that it was compiled with (GH-3615) | da-woods | 2020-05-17 | 1 | -1/+2 |
| | | | When it's merged into the main module, wrap it in a CompilerDirectivesNode. | ||||
* | Rewrite the C property feature (GH-3571) | scoder | 2020-05-04 | 1 | -2/+1 |
| | | | | | | | | | | | * Rewrite C property support (GH-2640) based on inline C methods. Supersedes GH-2640 and GH-3095. Closes GH-3521. * Test fix for `numpy_parallel.pyx`: avoid depending on whether "nd.shape" requires the GIL or not. * Turn NumPy's "ndarray.data" into a property to avoid direct struct access. * Make "ndarray.size" accessible without the GIL. | ||||
* | add a new ReplacePropertyNode pass | mattip | 2018-11-13 | 1 | -1/+2 |
| | |||||
* | Make raise-statements inside of nogil blocks automatically acquire the GIL, ↵ | Stefan Behnel | 2018-06-03 | 1 | -1/+2 |
| | | | | instead of requiring an explicit ``with gil`` block around them. | ||||
* | Make compiler pipeline a bit nicer to profile. | Stefan Behnel | 2017-08-21 | 1 | -3/+17 |
| | |||||
* | Simplify TrackNumpyAttributes transform. | Stefan Behnel | 2017-08-21 | 1 | -2/+1 |
| | |||||
* | Always report fatal errors. | Robert Bradshaw | 2017-07-08 | 1 | -1/+1 |
| | | | | | | Previously these could be suppressed if error holding was in place. This was noticed in #1746. | ||||
* | Add a Pythran backend for Numpy operation | Adrien Guinet | 2017-06-17 | 1 | -1/+2 |
| | | | | | | | | | | | | When the user asked for it (thanks to the --np-pythran flag), use Pythran's Numpy implementation as a backend for numpy operation. This flag forces the C++ mode, as the Pythran implementation is written in C++. Distutils integration through the 'np_pythran' flag of the cythonize API is also provided. This commit also adds a Pythran mode for the tests, that can enable the pythran mode for the C++ tests, and allows the reuse of Cython tests to test for the Pythran integration. | ||||
* | rely on code generation phase to include required utility code instead of ↵ | Stefan Behnel | 2016-08-14 | 1 | -25/+0 |
| | | | | always including all of it in a separate pipeline phase | ||||
* | merge DecoratorTransform and PropertyTransform | Stefan Behnel | 2015-11-07 | 1 | -2/+1 |
| | |||||
* | Add a pass transforming Python-style properties in cdef class into ↵ | Emmanuel Gil Peyrot | 2015-11-05 | 1 | -1/+2 |
| | | | | | | | | | | Cython-style properties. This makes properties work properly in cdef classes, and gives them the exact same AST as the “property something:” blocks, whose syntax should probably be deprecated now. Fixes T264. | ||||
* | pass correct CythonScope into CythonUtilityScope tree generation (used to be ↵ | Stefan Behnel | 2015-10-26 | 1 | -1/+1 |
| | | | | None) | ||||
* | minor code reformatting | Stefan Behnel | 2015-09-17 | 1 | -0/+5 |
| | |||||
* | More determanistic utility code ordering. | Robert Bradshaw | 2015-09-05 | 1 | -5/+4 |
| | |||||
* | Fix a couple of tests due to utility code changes. | Robert Bradshaw | 2015-09-03 | 1 | -1/+3 |
| | |||||
* | Make cpdef enums into first-class types. | Robert Bradshaw | 2015-09-03 | 1 | -0/+25 |
| | | | | | | | | | | | | | | For example cpdef enum Eggs SOFT HARD SCRAMBLED produces three constants with int values that print as strings, and a type Eggs with attributes Eggs.SOFT, etc. and list(Eggs) giving the set of all enum values. Instantiating Eggs with a numeric or string value will return the appropriate constant. | ||||
* | Merge branch '0.23.x' | Stefan Behnel | 2015-08-09 | 1 | -0/+1 |
|\ | |||||
| * | fix #855: make "import *" include all necessary "from_py" coercion helper ↵ | Stefan Behnel | 2015-08-09 | 1 | -0/+1 |
| | | | | | | | | functions | ||||
* | | minor code beautification | Stefan Behnel | 2015-08-09 | 1 | -2/+8 |
|/ | |||||
* | adapt some more syntax to Py2/Py3 | Stefan Behnel | 2015-07-25 | 1 | -3/+3 |
| | |||||
* | make dict iteration compatible with Py2/Py3 | Stefan Behnel | 2015-07-25 | 1 | -2/+2 |
| | |||||
* | 2to3: Apply the 'except' fixer | Petr Viktorin | 2015-07-25 | 1 | -3/+3 |
| | |||||
* | implement "async with" (PEP 492) | Stefan Behnel | 2015-05-23 | 1 | -1/+1 |
| | |||||
* | Undo --embed -> __main__ conversion. | Robert Bradshaw | 2015-04-27 | 1 | -4/+1 |
| | |||||
* | Rename module to __main__ in embed mode. | Robert Bradshaw | 2015-04-24 | 1 | -3/+5 |
| | | | | | | This is more consistent with the execution of "python foo.py" and also allows for compilation of files that don't obey the module naming rules. | ||||
* | change pipeline order to include tree changes made by structural optimisers ↵ | Stefan Behnel | 2015-03-19 | 1 | -2/+2 |
| | | | | in OptimizeBuiltinCalls run | ||||
* | remove unclear comment and add docstring to explain why | Stefan Behnel | 2014-11-15 | 1 | -1/+1 |
| | | | | | --HG-- extra : transplant_source : %C4Y%8Fo%10QD%23%A6%FB%B6%AF%3B%D6%C9%A9%09%C4%0D%A8 | ||||
* | use explicit relative imports everywhere and enable absolute imports by default | Stefan Behnel | 2014-06-17 | 1 | -38/+38 |
| | |||||
* | add a directive to disable SwitchTransform | Alok Singhal | 2014-04-22 | 1 | -1/+1 |
| | | | | | SwitchTransform is unable to detect all cases of duplicate values, which result in errors at compile time in the generated code. | ||||
* | fix some unnecessary Py2-isms in the code base | Stefan Behnel | 2014-01-17 | 1 | -1/+1 |
| | |||||
* | Cimported name mangling. | Robert Bradshaw | 2014-01-07 | 1 | -0/+4 |
| | |||||
* | Add support for external C++ template functions. | Robert Bradshaw | 2013-12-26 | 1 | -1/+1 |
| | | | | | | The syntax follows that of template classes, namely cdef T foo[T](T, ...) | ||||
* | fix crash when looking up closure names in OptimizeBuiltinCalls transform ↵ | Stefan Behnel | 2013-12-24 | 1 | -1/+1 |
| | | | | (after running CreateClosureClasses transform) | ||||
* | move qualname calculation transform a little later in the pipeline | Stefan Behnel | 2013-11-16 | 1 | -1/+1 |
| | |||||
* | reimplement PEP 3155 __qualname__ calculation in a dedicated transform to ↵ | Stefan Behnel | 2013-11-15 | 1 | -0/+2 |
| | | | | base it on the node structure instead of the scopes (which fails for class scopes) | ||||
* | In cimport_from_pyx mode don't treat "cdef extern from" variables as being ↵ | Nikita Nemkin | 2013-04-06 | 1 | -1/+2 |
| | | | | defined, preventing erroneous cross-module cimport. |