Mulberry32 constructor

Mulberry32([
  1. int? seed32
])

Implementation

Mulberry32([int? seed32]) {
  // although it's "32", it still needs long values
  if (!INT64_SUPPORTED) {
    throw Unsupported64Error();
  }
  if (seed32 != null) {
    RangeError.checkValueInInterval(seed32, 0, 0xFFFFFFFF);
    _state = seed32;
  } else {
    _state = (DateTime.now().millisecondsSinceEpoch ^ hashCode) & 0xFFFFFFFF;
  }
}