Proposal for SentinelInputRange
Andrej Mitrovic
andrej.mitrovich at gmail.com
Wed Feb 27 21:03:58 PST 2013
On Thursday, 28 February 2013 at 04:58:23 UTC, Walter Bright
wrote:
> On 2/27/2013 8:01 PM, John Colvin wrote:
>> Why must sentinel be known at compile time? I don't see what's
>> in the way of it
>> being a runtime argument.
>
> Performance!
>
> It should be usable as a case in a switch statement.
Little did you know about this bug:
http://d.puremagic.com/issues/show_bug.cgi?id=5862
:)
But I guess this defeats the purpose of the switch statement
(i.e. optimizations).
Btw can we get a clear opinion on whether 5862 is an actual bug
that needs to be fixed?
More information about the Digitalmars-d
mailing list