Tag patterns

Nested Patterns

We can nest patterns as deep as we like. Anywhere we put a variable in our pattern, we can put another pattern. exception BadTriple fun...

Functions and Type Inference

If you use patterns to access records or function arguments, you usually do not need to specify their types. They will be inferred from...

Functions, Pattern Matching And Val Bindings

The pattern {f1=x1, ..., fn=xn} will match against a record (assuming all the types match) {f1=v1,...,fn=vn}. Note that since all tuples...