Le mardi 8 janvier 2013, Andrew Collette a écrit :
Hi,
> Keep in mind that in the third option (current 1.6 behavior) the dtype is
> large enough to hold the random number, but not necessarily to hold the
> result. So for instance if x is an int16 array with only positive values,
> the result of this addition may contain negative values (or not, depending
> on the number being drawn). That's the part I feel is flawed with this
> behavior, it is quite unpredictable.
Yes, certainly. But in either the proposed or 1.5 behavior, if the
values in x are close to the limits of the type, this can happen also.