rename PYREX_WITHOUT_ASSERTIONS -> CYTHON_WITHOUT_ASSERTIONS
authorLisandro Dalcin <dalcinl@gmail.com>
Fri, 26 Nov 2010 15:58:15 +0000 (12:58 -0300)
committerLisandro Dalcin <dalcinl@gmail.com>
Fri, 26 Nov 2010 15:58:15 +0000 (12:58 -0300)
--HG--
extra : rebase_source : 7fea7f050894df69b66a2bdb843ce1885ef7ef7a

Cython/Compiler/ModuleNode.py
Cython/Compiler/Nodes.py

index 5a843e962153810fca2ab3eee7238b015ca90f9a..b8f370f85711aa236578510001c990282b43d915 100644 (file)
@@ -645,6 +645,11 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
         code.putln("#include <math.h>")
         code.putln("#define %s" % Naming.api_guard_prefix + self.api_name(env))
         self.generate_includes(env, cimported_modules, code)
+        code.putln("")
+        code.putln("#ifdef PYREX_WITHOUT_ASSERTIONS")
+        code.putln("#define CYTHON_WITHOUT_ASSERTIONS")
+        code.putln("#endif")
+        code.putln("")
         if env.directives['ccomplex']:
             code.putln("")
             code.putln("#if !defined(CYTHON_CCOMPLEX)")
index b453a27b5d8ef02b8bed8a722e8468f57b797c48..10706766af77d56a8a5bec6fdcb42a4d885937ea 100644 (file)
@@ -4000,7 +4000,7 @@ class AssertStatNode(StatNode):
     gil_message = "Raising exception"
     
     def generate_execution_code(self, code):
-        code.putln("#ifndef PYREX_WITHOUT_ASSERTIONS")
+        code.putln("#ifndef CYTHON_WITHOUT_ASSERTIONS")
         self.cond.generate_evaluation_code(code)
         code.putln(
             "if (unlikely(!%s)) {" %