I'm working on adding support for the bool dtype for sparse matrices. But I'm having some problems
I'm adding a wrapper for the npy_bool type. I've included a file called bool_ops.h which basically contains:
typedef npy_int8 npy_bool_wrapper;
Then I included bool_ops.h and the wrapper npy_bool_wrapper in sparsetools.i and numpy.i where I thought it was necessary. So that the typemaps for the npy_bool type are generated.
TypeError: Array of type 'byte' required. Array of type 'bool' given
Which is not what I expected because the typemaps for bool type should now be generated.
Why is order important here? I included npy_bool_wrapper where I did because the Numpy C api says npy_bool is an unsigned char. I'm currently trying to reorder INSTANTIATE_ALL to make things work.
Thanks in advance,