Version française
Home     About     Download     Resources     Contact us    
Browse thread
If OCaml were a car
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Luca de Alfaro <luca@d...>
Subject: Re: [Caml-list] If OCaml were a car
The only thing about Ocaml I mind, is that it a bit like German is, in that
all the verbs at the end come.  And there nothing wrong is, but it for some
strange reading makes, and it strange is that this from France comes.

I still somewhat puzzled am, at reading:

let f x =
  [humonguous definition 50 lines spanning]
in List.iter f l

because the only way I make sense of this can, is by first looking at where
f used is, and only then reading its definition.
I much rather write would:

do List.iter f l
where f x = [humonguous definition]

Maybe this problem with Ocamlp4 solvable is?

Luca

-------------

PS: Yes, yes, I know why the let comes before the use, but it would still be
handy to have a pre-processor implement this do...where... construct.  Has
anyone done it already?
Yes, I also know that in German, unlike in Ocaml, the verbs do not always
come at the end... :-)

On 8/19/07, Erik de Castro Lopo <mle+ocaml@mega-nerd.com> wrote:
>
> Daniel Bünzli wrote:
>
> > Maybe I ride this car too often to realize (or I'm dumb) but I don't
> > get the joke about controls.
>
> I'm preet sure thats a reference to Ocaml's rather odd (in
> comparison to C/C++/Java/Perl/Python etc) syntax.
>
> Erik
> --
> -----------------------------------------------------------------
> Erik de Castro Lopo
> -----------------------------------------------------------------
> Perl  : executable line noise
> Python: executable pseudo-code
>
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs
>