grauzone wrote:
Walter Bright wrote:
のしいか (noshiika) wrote:
But I am a bit disappointed with the CaseRangeStatement syntax.
Why is it
case 0: .. case 9:
instead of
case 0 .. 9:
Or
case [0..10]:
?
Compatible to how list slicing works.
Ah yes, bikeshed issue, but my solution is more beautiful.
No, it isn't compatible. [0..10] for slices does not include the 10,
while the case range does. Using Andrei's syntax clearly makes the point
that it is different, and not confusingly similar to something very
different.