four 64-bit words, or 32 little-endian bytes (the byte
layout rand_xoshiro's from_seed reads, and the one SeededRng.state
returns). An all-zero seed is replaced by the SplitMix64 expansion of
zero, as the reference does.
Debug label: Object.prototype.toString reports the class name.
The 256-bit state as 32 little-endian bytes (a copy);
SeededRng.fromState resumes it exactly. (new SeededRng(state)
also resumes every state a generator can reach, but substitutes an
all-zero one.)
StaticforStaticfromThe generator whose state is exactly state: the 32 little-endian bytes
SeededRng.state returns, restored with no all-zero
substitution. This is provenance-mark's Xoshiro256StarStar::from_data;
bc-rand itself has no raw-state constructor. An all-zero state is
xoshiro's fixed point and draws zeros forever, as it does there; the
constructor, which is from_seed, substitutes it instead.
An independent generator at the same state.
The next 64-bit output of xoshiro256**.
The low 32 bits of a 64-bit draw (the reference wrapper's next_u32).
The samplers' fast path: one step, low 32 bits, no bigint.
The reference's RngCore::fill_bytes stream (rand_core's
fill_bytes_via_next over xoshiro256**): eight little-endian bytes per
64-bit step; a tail of five to seven bytes from one more step; a tail of
one to four bytes from xoshiro's own next_u32, the high half of a
step. This is what reference code reaching the generator through
rand_core generics draws (e.g. bc-crypto's Ed25519 key generation);
SeededRng.fillBytes is the other stream, fill_random_data.
A deterministic generator (xoshiro256**), identical to
rand_xoshiro'sXoshiro256StarStarfor the same seed.NOT cryptographically secure. For tests and reproducible fixtures only.
fillBytesdraws one 64-bit word per byte and keeps its low byte — the reference'sfill_random_data, which every seeded fixture downstream depends on. SeededRng.fillBytesPacked is the other stream,rand_core's packedfill_bytes.