Hi,
Today I noticed a strange compiler's tolerance.
The compiler will not protest here:
type foo = Bar | Baz
;;
match Bar with
| Bar _ -> ()
| Baz -> ()
Why doesn't the compiler protest that I used wildcard after "Bar" constructor?
(It does protest if I put any other pattern except for the wildcard).
This slightly breaks the logic. Doesn't it?
--
Caml-list mailing list. Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs