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
[Caml-list] Operators for Int64 and Int32
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2008-04-03 (19:50)
From: Micha³_Maciejewski <>
Subject: Re: [Caml-list] Operators for Int64 and Int32
2008/4/3, David Allsopp <>:
>  My problem with this, as someone who writes a lot of OCaml but uses Int64
>  and Int32 rarely, is that these operators aren't clearly anything to do with
>  Int64 or Int32 in terms of their "names" (symbols). Defining funny strings
>  of symbols to get around the (intentional) limitations of not having
>  operator overloading is IMHO not something that should be in the standard
>  library.

That was just an example, but I think that names of those operators
are as funny as the symbol  '@' . I don't see any relation between "@"
and lists. Just like between '!' and references, or '^' and strings.

In C you have the same operator '+' for ints and floats. OCaml
provides you with '+' and '+.' . So why not to have corresponding
operators for other types? It's better to have one rule than set of
rules to learn. Besides mathematical expressions in functional
languages should be IMHO as compact as it's possible.

Best regards,
Mlchal Maciejewski