Version française
Home     About     Download     Resources     Contact us    
Browse thread
Re: [Caml-list] Future of labels
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Mattias Waldau <mattias.waldau@a...>
Subject: [Caml-list] Example of Ocaml-syntax problem with ;
A misplaced ';' results in an error two expressions away.
The compiler compains at the last let in the following code.
It just says 'Syntax error'.

let _ = 1+2;

let _ = 2

let _ = 4

';' in Ocaml is really a problem for beginners, even if the rule
is rather simple: "Do not use any semicolons unless you really need
to separate expressions."

Would it be possible to make a better diagnosis on the semicolon 
above?

/mattias
-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr