I agree. Non-transitive type comparisons seems like very fishy business (it will be *very* surprising to whoever runs across it); I think there's a strong case for just breaking backwards compatability:
ERROR: 'char' is illegal as a buffer dtype due to being underspecified in the C standard, please use 'signed char' or 'unsigned char'. (Myself I always use uint8_t or int8_t rather than char...) Dag -- Sent from my Android phone with K-9 Mail. Please excuse my brevity. "Bradley M. Froehle" <brad.froe...@gmail.com> wrote: I think again this is an instance of the tests being incorrect, rather than the code. The failing numpy_tests are all cases where we instantiate a buffer of type 'b' (== 'signed char') but then try to use it as if it was a 'char'. The fix, of course is to just replace most instances of 'char' with 'signed char' in numpy_test.pyx: https://github.com/bfroehle/cython/compare/char-buffers In some sense NumPy does have a notion of 'char', namely a 1 character string. The only worry here, of course, is whether this change will painfully break existing code⦠-Brad Actually, this fix breaks numpy_test, and I'm not sure how to fix it given that numpy has no notion of a "possibly signed char" (unless we disallow using char/char* with numpy altogether, which is much more extreme, or don't enforce that signs match for char, which is likely more invasive). Ugh.
_______________________________________________ cython-devel mailing list cython-devel@python.org http://mail.python.org/mailman/listinfo/cython-devel