fix undefined symbol in Py<2.6 when assigning to bytes variables
authorStefan Behnel <scoder@users.berlios.de>
Sat, 10 Oct 2009 16:34:19 +0000 (18:34 +0200)
committerStefan Behnel <scoder@users.berlios.de>
Sat, 10 Oct 2009 16:34:19 +0000 (18:34 +0200)
Cython/Compiler/ModuleNode.py

index ce4b2534556367f251ebda6d5bd69eedfbf8abae..ed06bb18e600bfa7a9fc41f7cf62df88cf563a4f 100644 (file)
@@ -454,6 +454,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
         code.putln("  #define PyVarObject_HEAD_INIT(type, size) \\")
         code.putln("          PyObject_HEAD_INIT(type) size,")
         code.putln("  #define PyType_Modified(t)")
+        code.putln("  #define PyBytes_CheckExact(b) PyString_CheckExact(b)")
         code.putln("")
         code.putln("  typedef struct {")
         code.putln("     void *buf;")