the new base class does not call setSeed,
defensive programming against too early calls to setSeed are not useful anymore git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@797246 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
441880be46
commit
648a02f0b4
|
@ -202,12 +202,6 @@ public class MersenneTwister extends BitsStreamGenerator implements Serializable
|
|||
* @param seed the initial seed (64 bits integer)
|
||||
*/
|
||||
public void setSeed(long seed) {
|
||||
if (mt == null) {
|
||||
// this is probably a spurious call from base class constructor,
|
||||
// we do nothing and wait for the setSeed in our own
|
||||
// constructors after array allocation
|
||||
return;
|
||||
}
|
||||
setSeed(new int[] { (int) (seed >>> 32), (int) (seed & 0xffffffffl) });
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue