Option types and pattern matching.
Kagamin via Digitalmars-d
digitalmars-d at puremagic.com
Tue Oct 27 09:17:11 PDT 2015
On Tuesday, 27 October 2015 at 15:06:07 UTC, TheFlyingFiddle
wrote:
> The reason that I prefer that is not that I like the syntax
> really. It's just that if the only way to get a value is to
> pattern match on it then you are forced to consider the case
> where the value was not there.
If pattern matching is the only way, the get function above will
still work: it uses only pattern matching, nothing else.
More information about the Digitalmars-d
mailing list