I am following the wikibook on OCaml and they say that the integer type could have been constructed like that:
type int = 0 | 1 | 2 | (* .... *) | -1 | -2 | (* ... *) ;;
Later on, the book indicates that all constructors are words starting with an uppercase. There are also special constructors, true false and integers like 1, 2, 3.
So, back to utop. I type the following:
type d = 0 | 1 | 2 ;;
And I get a syntax error on the 0. What am I missing? Isn't 0 a constructor?