fix semantics of cmp() -- should not be a bint
authorRobert Bradshaw <robertwb@math.washington.edu>
Wed, 9 May 2007 07:31:34 +0000 (00:31 -0700)
committerRobert Bradshaw <robertwb@math.washington.edu>
Wed, 9 May 2007 07:31:34 +0000 (00:31 -0700)
Cython/Compiler/Symtab.py

index 4abec146c0ac54d43f44da52f102823ae4a9d4fb..515225d93554c2d5659f8f0815870e204c607d55 100644 (file)
@@ -484,7 +484,7 @@ class BuiltinScope(Scope):
     
     builtin_functions = {
       "hasattr": ["PyObject_HasAttrString", c_bint_type, (py_object_type, c_char_ptr_type)],
-      "cmp":     ["PyObject_Compare", c_bint_type, (py_object_type, py_object_type), None, True],
+      "cmp":     ["PyObject_Compare", c_int_type, (py_object_type, py_object_type), None, True],
       "repr":    ["PyObject_Repr", py_object_type, (py_object_type, ), 0],
 #      "str":     ["PyObject_Str", py_object_type, (py_object_type, ), 0],
       "unicode": ["PyObject_Unicode", py_object_type, (py_object_type, ), 0],