Tricky semantics of ranges & potentially numerous Phobos bugs

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Wed Oct 17 11:13:41 PDT 2012


On 10/17/12 1:29 PM, monarch_dodra wrote:
> On Wednesday, 17 October 2012 at 17:15:14 UTC, Andrei
> Alexandrescu wrote:
>> On 10/16/12 3:07 PM, H. S. Teoh wrote:
>>> Perhaps mark ranges with an .isTransient property
>>
>> isTransient!R is exactly the same thing as isInputRange!R &&
>> !isForwardRange!R.
>>
>> Andrei
>
> Technically, (isTransient!R) is just a subset of (isInputRange!R
> && !isForwardRange!R)
>
> "byDChar" (if it existed), would be a perfectly valid
> non-transient input only range.

Depends on implementation - popFront may actually wipe the character.

Andrei


More information about the Digitalmars-d mailing list