[Numpy-discussion] doctest improvements patch (and possible regressions)
Sun Dec 13 01:27:50 CST 2009
So far, no one has voiced objections, so should I go ahead and check
btw, thanks Mike, what about this one:
>>> (np.char.lstrip(c, ' ') == np.char.lstrip(c, '')).all()
... # XXX: is this a regression? this line now returns False -pi
... # np.char.lstrip(c,'') does not modify c at all.
Michael Droettboom, on 2009-12-09 06:04, wrote:
> Paul Ivanov wrote:
>> I marked up suspicious differences with XXX, since I don't know if
>> they're significant. In particular:
>> - shortening a defchararray by strip does not change it's dtype to a
>> shorter one (apparently it used to?)
> Yes. The new behavior is to return a string array with the same
> itemsize as the input array. That's primarily just the result of the
> new implementation rather than a thought out change, though.
> Sorry, just commenting on the parts I feel competent in :) But I think
> this is a great improvement. It would be nice to start doing doctests
> as a matter of course to keep the docs accurate.
More information about the NumPy-Discussion