Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Custom operators in the revised syntax
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-05-11 (14:36)
From: Nicolas Pouillard <nicolas.pouillard@g...>
Subject: Re: [Caml-list] Custom operators in the revised syntax
On 5/11/07, dmitry grebeniuk <> wrote:
> Shalom, Nicolas.
> NP> Today it's about custom operators. In the original syntax everyone
> NP> knows that's easy to define and use custom operators like ++, -->,
> >>>>, +|, =?=, ... and as many as you want.
>   As for me, the lack of custom infix operators in revised syntax
> is a feature that allows to keep code clean, without any
> "=?=" or "<<+".  The code "(func arg1 arg2)" is imho much
> more readable than "arg1 op arg2" because: 1. function name
> usually says something about the meaning of the function, 2. you
> don't need to remember operator's precedence and associativity
> to understand the code.

This seems reasonable, but that's more a guideline. The feature can be
present for that wants it. Moreover Camlp4 is about changing the
syntax, so one can buy the revised syntax without the fact of patching
syntaxes but features are here.

Nicolas Pouillard