From 74e27f940f6b67af678286f50ebb28ae4eb502ba Mon Sep 17 00:00:00 2001 From: Jason Paryani Date: Tue, 3 Sep 2013 11:54:58 -0700 Subject: [PATCH] Change == on StructSchema to return cbool --- capnp/capnp.pyx | 2 +- capnp/capnp_cpp.pxd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/capnp/capnp.pyx b/capnp/capnp.pyx index f2669ba..1ffdcb9 100644 --- a/capnp/capnp.pyx +++ b/capnp/capnp.pyx @@ -809,7 +809,7 @@ cdef class _StructSchema: def __richcmp__(_StructSchema self, _StructSchema other, mode): if mode == 2: - return bool(self.thisptr == other.thisptr) + return self.thisptr == other.thisptr elif mode == 3: return not (self.thisptr == other.thisptr) else: diff --git a/capnp/capnp_cpp.pxd b/capnp/capnp_cpp.pxd index db8e4f2..377f459 100644 --- a/capnp/capnp_cpp.pxd +++ b/capnp/capnp_cpp.pxd @@ -60,7 +60,7 @@ cdef extern from "capnp/schema.h" namespace " ::capnp": Field getFieldByName(char * name) - int operator == (StructSchema) + cbool operator == (StructSchema) cdef cppclass EnumSchema: cppclass Enumerant: