From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Delivered-To: caml-list@yquem.inria.fr Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id ECDC5BC88 for ; Sun, 6 Feb 2005 01:02:45 +0100 (CET) Received: from mail.physik.uni-muenchen.de (mail.physik.uni-muenchen.de [192.54.42.129]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j1602jfk015916 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Sun, 6 Feb 2005 01:02:45 +0100 Received: from localhost (unknown [127.0.0.1]) by mail.physik.uni-muenchen.de (Postfix) with ESMTP id 29C7420024 for ; Sun, 6 Feb 2005 01:02:45 +0100 (CET) Received: from mail.physik.uni-muenchen.de ([127.0.0.1]) by localhost (mail.physik.uni-muenchen.de [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 16231-01-10 for ; Sun, 6 Feb 2005 01:02:42 +0100 (CET) Received: from mailhost.cip.physik.uni-muenchen.de (kaiser.cip.physik.uni-muenchen.de [141.84.136.1]) by mail.physik.uni-muenchen.de (Postfix) with ESMTP id BE97920008 for ; Sun, 6 Feb 2005 01:02:42 +0100 (CET) Received: from eiger.cip.physik.uni-muenchen.de (eiger.cip.physik.uni-muenchen.de [141.84.136.54]) by mailhost.cip.physik.uni-muenchen.de (Postfix) with ESMTP id ADE3C26E89; Sun, 6 Feb 2005 01:02:42 +0100 (CET) Received: by eiger.cip.physik.uni-muenchen.de (Postfix, from userid 3092) id A62C23C8F; Sun, 6 Feb 2005 01:02:42 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by eiger.cip.physik.uni-muenchen.de (Postfix) with ESMTP id A3D392D686; Sun, 6 Feb 2005 01:02:42 +0100 (CET) Date: Sun, 6 Feb 2005 01:02:42 +0100 (CET) From: Thomas Fischbacher To: Thomas Fischbacher Cc: caml-list@yquem.inria.fr Subject: Re: [Caml-list] The boon of static type checking In-Reply-To: Message-ID: References: <891bd33905020213315a2ebb18@mail.gmail.com> <877e9a170502031856175260c8@mail.gmail.com> <877e9a17050203185674680413@mail.gmail.com> <200502041026.56107.jon@jdh30.plus.com> X-BOFH: Daemons did it MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: amavisd-new at physik.uni-muenchen.de X-Miltered: at nez-perce with ID 42055EA5.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 ocaml:01 ocaml:01 sed:01 compiler:01 closures:01 quirks:01 alas:01 naming:01 perl's:01 printf:01 cip:98 cip:98 lambda:01 lambda:01 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on yquem.inria.fr X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.2 X-Spam-Level: As this discussion got a bit heated up, it's perhaps appropriate to make a step backwards and ask the question: what is all this about, actually. First of all, I strongly suppose most people will agree with me that one peculiarity of the Ocaml community is that most of its members are quite multi-lingual, which I somewhat doubt e.g. with the Java community. This is very similar to perl, so it is perhaps appropriate to compare the role of ocaml to that of perl. Perl tried to integrate, and to build bridges. It not only inherits a lot from other languages and tools, but indeed is even such a good replacement for some of them (awk, sed, to some extent the shell) that they are even more or less obsoleted by perl: virtually anything one would want to do in awk can be done more easily, and nicer, in perl. While ocaml also inherits a lot from other languages, it is not and does not try to be a glue language similar to perl. It has its own philosophy, which one might or might not like, but independent of this, even those people who have good reason not to believe in some of the ideas central to ocaml, such as e.g. Hindley-Milner typing, or matching as an integral part of the language, will from time to time consider it as a highly useful tool to build solutions to some problems, even if they do not think about making ocaml their primary medium for expressing algorithmic ideas. Personally, I see the following quite good reasons to do something in ocaml: (1) Portability. (2) A good compiler. (3) The ability to create comparatively small standalone programs. (4) Availability of essential constructions, such as closures. (5) Availability of useful libraries. I think the points why I believe ocaml will never win over a noticeable share of especially the lisp community are clear now: there are some quirks of the language that in the long run make working with it less fun for lisp programmers than working with lisp - as they are regarded as a conceptual step backwards in that community. Nevertheless, they will be glad ocaml exists and will occasionally use it provided the language does not hurt them too much. There are a few things I experienced as such a nuisiance in the past I just had to talk to some people about that, at some point. Alas, this is what happened on the list - sorry if annoyed a few readers with that, but from the response I think it seems as if quite some of these issues not only I experienced as unnecessarily ugly. Some of them which may be improved perhaps should be improved. If I were to limit myself to naming only one ugly side of ocaml which I would like to see changed, this would be the unavailability of automatical printers for complicated composite nested data structures. That is, an equivalent of perl's Data::Dumper. Say, an extension of Printf so that one can use "%v" for generating such output. -- 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)