Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] single-line comment request
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Nickolay Semyonov-Kolchin <snob@s...>
Subject: Re: [Caml-list] single-line comment request
On Tuesday 08 April 2003 23:53, Alexander V. Voinov wrote:
> Hi All,
>
> Daniel M. Albro wrote:
> >     But ## is so *ugly*!  It just doesn't look OCaml-ic, since # is
> > already the object-call operator.  What other possibilities are there?
> > How about %, %%, --, ' ?  If "--" isn't used it might be nice.
>
> I'd vote for "--" or "%%". The need for a one-line comment is obvious
> for me. It's also a matter for quicker adoption among those who is
> practically working with Python, C++, Java etc.
>

===================================
        Objective Caml version 3.06

# let (--) = (+) ;;
val ( -- ) : int -> int -> int = <fun>
# let (%%) = (+) ;;
val ( %% ) : int -> int -> int = <fun>
# let (##) = (+) ;;
Syntax error
#

====================================

We must find a sequence that can't be used as a binary operator.

P.S.
	I have nothing against '--', '%%' or whatever. I just want to see easily 
typed single-line comment in Ocaml.

Nickolay

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners