From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id TAA02970; Thu, 11 Jul 2002 19:02:43 +0200 (MET DST) Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id TAA02965 for caml-list@pauillac.inria.fr; Thu, 11 Jul 2002 19:02:42 +0200 (MET DST) Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id AAA20323 for ; Thu, 11 Jul 2002 00:29:25 +0200 (MET DST) Received: from swordfish.cs.caltech.edu (swordfish.cs.caltech.edu [131.215.44.124]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id g6AMTNn13211 for ; Thu, 11 Jul 2002 00:29:24 +0200 (MET DST) Received: from orchestra.cs.caltech.edu (orchestra.cs.caltech.edu [131.215.44.20]) by swordfish.cs.caltech.edu (Postfix) with ESMTP id 31C08DF260; Wed, 10 Jul 2002 15:29:21 -0700 (PDT) Received: (from mvanier@localhost) by orchestra.cs.caltech.edu (8.11.6/8.9.3) id g6AMTKB22278; Wed, 10 Jul 2002 15:29:20 -0700 Date: Wed, 10 Jul 2002 15:29:20 -0700 Message-Id: <200207102229.g6AMTKB22278@orchestra.cs.caltech.edu> X-Authentication-Warning: orchestra.cs.caltech.edu: mvanier set sender to mvanier@cs.caltech.edu using -f From: Michael Vanier To: skaller@ozemail.com.au Cc: warplayer@free.fr, oleg_inconnu@myrealbox.com, caml-list@inria.fr In-reply-to: <3D2C5B77.6060303@ozemail.com.au> (message from John Max Skaller on Thu, 11 Jul 2002 02:06:15 +1000) Subject: Re: [Caml-list] Universal Serializer (was: productivity improvement) References: <200207081952.PAA28813@hickory.cc.columbia.edu> <15657.61603.221054.289184@spike.artisan.com> <200207090442.AAA05638@hickory.cc.columbia.edu> <001f01c2271e$8037adf0$d100a8c0@warp> <3D2C5B77.6060303@ozemail.com.au> Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk > Date: Thu, 11 Jul 2002 02:06:15 +1000 > From: John Max Skaller > > > > >BTW OCaml functional programming and memory management are two ways of > >increasing productivity. Pattern matching on structures is also wonderful. > >For most of the programs, I will say that the productivity rate against C is > >around 1:3. > > > >Nicolas Cannasse > > > You must be an academic.:-) Try between 10:1 and 100:1, > *assuming* that any libraries you need are available, > and a reasonably complex piece of software. > I agree, but the productivity increase is going to depend a lot on the experience and skill of the ocaml programmer. As a newbie, I find myself using a lot of lame imperative idioms before discovering more elegant (and concise) functional ones. > You just can't underestimate how difficult it is to find > bugs in C codes of reasonable size. Such bugs almost never > happen in Ocaml. Definitely, although the same could be said for java or C#, if by "such bugs" you mean memory leaks and memory corruption. For a more ocaml-specific example, I find that algebraic data types with pattern-matching (and the compiler warnings that occur if you fail to match all patterns) is something that ocaml has that java/C# don't and which can massively improve the quality of code (as well as making it much more comprehensible). > The biggest problem in Ocaml is type inference, > and the resulting loss of localisation of error diagnostics, but > such compile time errors can be resolved *definitely*; > that is, you know for sure when you've fixed them > (because the compiler stops hassling you). What do you mean by "loss of localisation of error diagnostics"? Do you mean that a type error in one location giving an expression which can still compile (but to the wrong type) results in an obscure error message elsewhere? I agree that that's occasionally a minor pain, but it's hardly in the same league with memory leaks etc. If that's ocaml's biggest problem, then ocaml is the best computer language I've ever seen. > > Ohhhh.. just imagine if GTK/Gnome/Gui stuff on RH linux > were written in Ocaml .. it might actually work! > *drool* I would totally *love* to have this. Mike ------------------- 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