On 07/08/2011 01:31 PM, Mark Wiebe wrote: > I've just made pull request 105: > > https://github.com/numpy/numpy/pull/105 >
It's merged, which is good, but I have a suggestion relevant to that pull and I suspect to many others to come: use defines and macros to consolidate some of the implementation details. For example: #define MASK_TYPE npy_uint8 #define EXPOSE 1 #define HIDE 0 #define EXPOSED(mask) ( (*(MASK_TYPE *)mask)&0x01 == EXPOSE ) etc. The potential advantages are readability, reduction of scope for typos, and ease of testing alternative implementation details, should that turn out to be desirable. I am assuming that only a few expressions like EXPOSED will be needed *many* places in the code. Eric _______________________________________________ NumPy-Discussion mailing list [email protected] http://mail.scipy.org/mailman/listinfo/numpy-discussion
