Original ticket http://projects.scipy.org/numpy/ticket/210 on 2006-07-28 by @alberts, assigned to unknown.
Trying to construct the following dtype should probably raise a !TypeError:
#!python
dt = N.dtype({'names':[123],'formats':[N.intc]})
If not, one can create an array but not access its fields:
#!python
In [2]: import numpy as N
In [3]: dt = N.dtype({'names':[123],'formats':[N.intc]})
In [4]: x = N.empty((5,), dt)
In [5]: x[123]
IndexError: index out of bounds
Tested with !NumPy 1.0b2.dev2915.
Reactions are currently unavailable
Original ticket http://projects.scipy.org/numpy/ticket/210 on 2006-07-28 by @alberts, assigned to unknown.
Trying to construct the following dtype should probably raise a !TypeError:
#!python dt = N.dtype({'names':[123],'formats':[N.intc]})If not, one can create an array but not access its fields:
#!python In [2]: import numpy as N In [3]: dt = N.dtype({'names':[123],'formats':[N.intc]}) In [4]: x = N.empty((5,), dt) In [5]: x[123] IndexError: index out of boundsTested with !NumPy 1.0b2.dev2915.