[Pyrex] enum regression 0.9.5?

Chris Mellon arkanes at gmail.com
Mon Jan 29 14:53:29 UTC 2007


I subscribed after this thread was started, so I'm faking a reply here.

Previously posted patch allowed any 2 enum types to be compared, which
is probably wrong. Using

elif type1.is_enum and type2.is_enum and (type1.cname == type2.cname):
            return 1

seems to work for me, and it works correctly in the presence of
typedefed aliases.

I'm attaching a test case, it fails with unpatched 0.9.5 but works
correctly with the patch above.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t.pyx
Type: application/octet-stream
Size: 795 bytes
Desc: not available
Url : http://lists.copyleft.no/pipermail/pyrex/attachments/20070129/c217a975/attachment.obj 


More information about the Pyrex mailing list