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
[Caml-list] OCaml popularity
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2003-03-11 (10:23)
From: Pierre Weis <pierre.weis@i...>
Subject: Re: [Caml-list] OCaml popularity

To briefly answer your question: I think Caml is not so popular
because there were no big company or extremely important and
successful tool to advertize it all over the place (like Sun did for
Java or Unix for C). In short, Caml is more and more recognized as a
powerful and well-crafted language among expert programmers, but it is
almost unknown to the general audience.

> There is few beginnings of answers two your question :
> - some people are telling that you need a PhD to fully understand (and
> appreciate) OCaml . That's somehow exagerate, but not so much, since you
> need to know at least several programming languages to really understand how
> Ocaml is great compared to them :)

You're right: it seems that people need to suffer a lot by programming
(bugs) in C or Java before they really appreciate Objective Caml.

> - about the syntax, I had some experience of teaching Ocaml to some people,
> plus my own Ocaml-learning experience. The current syntax take some time to
> get, but is quite good and brief once you got it. But you have to really
> understand the underlying typing algorithm when you got a type error. I
> think this is perhaps the biggest problem with OCaml syntax right now :
> while C/Java will tell you " missing ';' " , Ocaml will simply said " Syntax
> Error ".

In this case, you should try camlp4 (ocamlc -pp camlp4o): it very
often gives a fairly good hint about the syntax error (although you
have to know something about the Caml AST to fully benefit from the
error report).

> The same goes for typing. Just make write few lines to a beginner,
> he will hit into something like " this expression has type unit -> string
> but is here used with 'a -> unit" ( quite an obvious error message for
> people here, but perhaps a little bit difficult to get when you don't know
> the language )

You are also right: this language has to be taught before being
profitably used. The darker side of this fact is that conversely, you
have to learn it. This may be the main drawback of Objective Caml:
there is no ``Objective Caml for dummies''. That may be the price to
pay to use a powerful and theoretically well-founded language.

As a long time Caml teacher, I used to start the course with a small
introductory speech that roughly goes like that: «you're smart guys,
all of you; today you are smart {\em and} lucky, since you get the
opportunity to learn the smartest programming language I know, so
smart that it could change your way of thinking about programs and
computers. Indeed, it will not be easy, but you will gain a lot of new
ideas from Caml and this is worth the effort!»

After such an introduction, some students are afraid and some are
enthousiastic; after a while, they all discover that this is plain
true: learning Caml is indeed profitable to the way you deal with
programming problems, but on the other hand, yes, it is not so easy !

Pierre Weis

INRIA, Projet Cristal, Pierre.Weis@inria.fr, http://pauillac.inria.fr/~weis/

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