Proposal for SentinelInputRange
Walter Bright
newshound2 at digitalmars.com
Thu Feb 28 13:40:25 PST 2013
On 2/28/2013 9:05 AM, deadalnix wrote:
> I see nothing that can't be done by an optimizing compiler. Maybe something is,
> but I can't find it. And the example you pointed me aren't.
Tell me how front() will be optimized out to this.
case '>':
p++;
if (*p == '=')
{ p++;
t->value = TOKge; // >=
}
else if (*p == '>')
{ p++;
if (*p == '=')
{ p++;
t->value = TOKshrass; // >>=
}
else if (*p == '>')
{ p++;
if (*p == '=')
{ p++;
t->value = TOKushrass; // >>>=
}
else
t->value = TOKushr; // >>>
}
else
t->value = TOKshr; // >>
}
else
t->value = TOKgt; // >
return;
More information about the Digitalmars-d
mailing list