English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
Estimating the size of the ocaml community
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2005-02-03 (21:58)
From: Paul Snively <psnively@m...>
Subject: Re: [Caml-list] Estimating the size of the ocaml community
Hash: SHA1

On Feb 3, 2005, at 1:16 PM, Thomas Fischbacher wrote:
> (1) I by far do not have the flexibility in extending the language with
> own syntax which I have in Lisp.
I have to respectfully disagree with this: IMHO, entirely too much is 
made of Lisp's macros (as distinct from Scheme's hygenic macros)! With 
camlp4, I have the ability to go from any concrete syntax I have an 
expander for to O'Caml's AST and back. This is used to good effect in 
Graydon Hoare's One Day Compiler presentation.

> (2) Speaking of syntax, there's a lot of unnecessary cruft in virtually
> any language besides LISP (or rather, Scheme).
Well, sure, given that in Lisp you're writing the AST by hand. :-)

> (3) The type system is annoying. People claim it helps catching errors,
> but my impression is it only catches those which I would never make
> anyway. On the other hand, I cannot just have e.g. a function like
> POSITION-IF that returns a number or nil. (Either one has to work with
> exceptions, or wrap things up using the Maybe monad. Exception 
> techniques
> may interfere badly with tail recursion in some cases.)
I guess I don't see the problem with "option" or variants.

> (4) There are a few other minor issues, such as a lack of
> multiple-value-bind, which I personally find slightly annoying, but
> not essential.
I would agree with this.

> (5) It does not behave as expected wrt module interfaces, as these 
> include
> md5 sums over source.
This is a pain, yes, but given how powerful the module system is, and 
the fact that, e.g. inlining is done across modules, I'm willing to 
accept this.

> (6) I cannot easily COMPILE a function to fast machine code from the 
You may wish to try "Nativize." It's in the Humps.

> (7) I cannot easily (format t "DEBUG: compsite-thingy-bla-now-is ~A~%" 
> bla).
I don't quite follow; is there something wrong with Printf?

> (8) There are quite some instances where Ocaml's syntax is
> counter-intuitive to the extent of becoming a source of ugly mistakes,
> due to interference with conventions people are used to from other
> languages. I do not talk about (p,q) as x vs. x as (p,q) (or x@(p,q)) -
> as everyone else (e.g. SML, Haskell) does it, but rather about issues
> like for x=0 to 3 counting 0,1,2,3, or "\010" meaning "\x0a" instead of
> "\x08", and such.
I was thrown by it for a while, too, but now I find it quite natural, 
and everything else doesn't seem to fit. Having said that, in my day 
job, "everything else" means C++. Enough said. :-)

> (9) It really annoys having +, +., and +/. Furthermore, it seems a bit
> inconsistent, as on the other hand, we have e.g. < and not </.
I think we all eagerly await G'Caml, don't we?

> I know quite well that some people will consider some of these points
> actually as "good" features, and think the "problems" I face can be 
> traced
> back to me being quite misguided about programming in general. For 
> sure, I
> should not expect Ocaml to be LISP, as it isn't. But I don't do that. 
> :-)
> It's only that I experienced a few things in LISP as quite nice, and 
> am a
> little bit annoyed when I cannot use them. But only a little bit. ;-)
> Still, Ocaml also has a few niceties that are missing in LISP. After 
> all,
> it is still among my favourite languages. C++, Java, JavaScript 
> certainly
> are not.
Amen, and thanks for the thorough, well-articulated points.

> -- 
> regards,               tf@cip.physik.uni-muenchen.de              (o_
>  Thomas Fischbacher -  http://www.cip.physik.uni-muenchen.de/~tf  //\
> (lambda (n) ((lambda (p q r) (p p q r)) (lambda (g x y)           V_/_
> (if (= x 0) y (g g (- x 1) (* x y)))) n 1))                  (Debian 
> GNU)
> _______________________________________________
> 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
Best regards,
Paul Snively

Version: GnuPG v1.4.0 (Darwin)