On Monday, 11 May 2020 at 12:20:06 UTC, Jack Applegame wrote: > assert(rng.front == 1); Damn! I made a typo. It must be: assert(rng.front == '1') So the second example works fine.