opNext: Simplified ranges
Tomer at Weka
Tomer at Weka
Sun Nov 6 07:55:13 UTC 2022
On Sunday, 6 November 2022 at 01:48:04 UTC, Walter Bright wrote:
> We didn't use the "next" protocol for ranges because one cannot
> test for existence of the next element without consuming it.
But that's exactly the issue - I have to produce the element in
the range's ctor, which essentially requires a "non-popping
popNext" to determine if it's empty and assign the front
-tomer
More information about the Digitalmars-d
mailing list