diff options
author | Stefan Behnel <stefan_ml@behnel.de> | 2016-07-15 08:34:37 +0200 |
---|---|---|
committer | Stefan Behnel <stefan_ml@behnel.de> | 2016-07-15 08:34:37 +0200 |
commit | 425863ba1a5ea60d27ca7325124500fd26bf1994 (patch) | |
tree | 62eb76fabed78210a70fe220666b5c2c38b0c148 | |
parent | 272a299f22512551838bbebdb441e2d790e03f45 (diff) | |
parent | 320f67b5b595cb5393a25b2e615d9b54bcfa64d5 (diff) | |
download | cython-425863ba1a5ea60d27ca7325124500fd26bf1994.tar.gz |
Merge branch '0.24.x'
Conflicts:
CHANGES.rst
docs/src/reference/compilation.rst
-rw-r--r-- | CHANGES.rst | 35 | ||||
-rw-r--r-- | Cython/Compiler/ModuleNode.py | 6 |
2 files changed, 31 insertions, 10 deletions
diff --git a/CHANGES.rst b/CHANGES.rst index bd8878124..7520bdc4c 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -11,15 +11,10 @@ Features added * Dynamic Python attributes are allowed on cdef classes if an attribute ``cdef dict __dict__`` is declared in the class. Patch by empyrical. -* IPython cell magic supports "-3" argument as in "%%cython -3". - * for-loop iteration over "std::string". * Cython implemented C++ classes can make direct calls to base class methods. -* Macros defined in the ``distutils`` compiler option do not require values - anymore. Patch by Ian Henriksen. - * New directive ``cython.no_gc`` to fully disable GC for a cdef class. * Buffer variables are no longer excluded from ``locals()``. @@ -31,17 +26,37 @@ Bugs fixed * Division of complex numbers avoids overflow by using Smith's method. -* Namespaced C++ types could not be used as memory view types due to lack of - name mangling. Patch by Ivan Smirnov. +Other changes +------------- + +* Usage of ``Cython.Distutils.build_ext`` is now discouraged. + + +0.24.1 (2016-07-15) +=================== + +* IPython cell magic was lacking a good way to enable Python 3 code semantics. + It can now be used as "%%cython -3". * Follow a recent change in `PEP 492 <https://www.python.org/dev/peps/pep-0498/>`_ and CPython 3.5.1 that now requires the ``__aiter__()`` method of asynchronous iterators to be a simple ``def`` method instead of an ``async def`` method. -Other changes -------------- +* Coroutines and generators were lacking the ``__module__`` special attribute. -* Usage of ``Cython.Distutils.build_ext`` is now discouraged. +* Namespaced C++ types could not be used as memory view types due to lack of + name mangling. Patch by Ivan Smirnov. + +* Assignments between the identical C++ types that were declared with differently + typedefed template types could fail. + +* Rebuilds could fail to evaluate dependency timestamps in C++ mode. + Path by Ian Henriksen. + +* Macros defined in the ``distutils`` compiler option do not require values + anymore. Patch by Ian Henriksen. + +* Minor fixes for MSVC, Cygwin and PyPy. 0.24 (2016-04-04) diff --git a/Cython/Compiler/ModuleNode.py b/Cython/Compiler/ModuleNode.py index 1d475c185..a8cdf8998 100644 --- a/Cython/Compiler/ModuleNode.py +++ b/Cython/Compiler/ModuleNode.py @@ -2056,8 +2056,14 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode): old_error_label = code.new_error_label() code.putln("if (0);") # so the first one can be "else if" + msvc_count = 0 for name, entry in sorted(env.entries.items()): if entry.is_cglobal and entry.used: + msvc_count += 1 + if msvc_count % 100 == 0: + code.putln("#ifdef _MSC_VER") + code.putln("if (0); /* Workaround for MSVC C1061. */") + code.putln("#endif") code.putln('else if (__Pyx_StrEq(name, "%s")) {' % name) if entry.type.is_pyobject: if entry.type.is_extension_type or entry.type.is_builtin_type: |