Proposal for SentinelInputRange

Michel Fortin michel.fortin at michelf.ca
Wed Feb 27 18:07:51 PST 2013


On 2013-02-28 02:05:20 +0000, "timotheecour" <thelastmammoth at gmail.com> said:

> On Thursday, 28 February 2013 at 01:56:33 UTC, Walter Bright wrote:
>> On 2/27/2013 5:53 PM, Zach the Mystic wrote:
>>> What if more than one
>>> value can end the range, EOF, '\0'?
>> 
>> I have never seen a need for that.
> 
> how about a predicate isSentinel instead of a fixed sentinel value?
> That'd allow more flexibility such as more than one sentinel value.

Not usable in a switch/case statement.

-- 
Michel Fortin
michel.fortin at michelf.ca
http://michelf.ca/



More information about the Digitalmars-d mailing list