[SciPy-dev] adding new attribute to data type objects

Christopher Hanley chanley at stsci.edu
Tue Nov 1 11:52:28 CST 2005


Hi Travis,

In numarray a user is able to say the following in order to get the size
of a data type in bytes:

numarray.Int32.bytes

This is a useful feature that is used in multiple locations within the
Records implementation.  I cannot find an equally simple functionality
within newcore.  There are obvious work arounds that I could use but I
fear that they aren't as efficient as having a simple attribute on the
data type object.  Is there some easy way of adding a similar feature to 
scipy_core?

Thanks,
Chris




More information about the Scipy-dev mailing list