--- In ocaml_beginners%40yahoogroups.com">ocaml_beginners
yahoogroups.com, Joel Reymont <joelr1
...> wrote:
>
>
> On May 21, 2007, at 9:58 AM, dmitry grebeniuk wrote:
>
> > Although original syntax allows to write code with
> > less "punctuation" symbols and the code looks nicer,
> > revised syntax targets at code safety.
>
> "The revised syntax is an alternative syntax for OCaml. Its purposes
> are 1/ fix some problems of the normal syntax (unclosed constructions
> sometimes introducing ambiguities, constructors arity, end of top
> level phrases and structure items, etc) 2/ avoid unjustified double
> constructions (":=" vs ``<-'', ``fun'' vs ``function'',
> ``begin..end'' vs parentheses) or concepts (types and types
> declarations) 3/ bring some ideas (lists, types). In a word, propose
> a syntax which be more logical, simpler, more consistent and easier
> to parse and to pretty print."
>
> I see nothing about safety here and I haven't encountered any
> problems with the old syntax so far.
After having read carefuly
http://caml.inria.fr/pub/docs/tutorial-camlp4/tutorial005.html
it seems to me that what dmitry calls "safety" is mainly about
eliminating ambiguities. At least, that's why I understand and agree
with (now
.
The idea is that there is no ambiguity in what you write,
-> therefore more chances that what the compiler understand is what
you really meant,
-> therefore more chances that "if it compiles it works",
-> therefore it is more safe.
Don't you agree ?
Vincent
.