From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 9A213BC69 for ; Sun, 5 Aug 2007 19:01:34 +0200 (CEST) Received: from orion.metastack.com (orion.metastack.com [80.177.38.218]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l75H1XbN025036 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Sun, 5 Aug 2007 19:01:34 +0200 Received: from treble (cpc2-cmbg6-0-0-cust535.cmbg.cable.ntl.com [81.107.34.24]) (authenticated bits=0) by orion.metastack.com (8.13.4/8.13.3) with ESMTP id l75Gmb7P031455 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) for ; Sun, 5 Aug 2007 17:48:38 +0100 From: "David Allsopp" To: "OCaml List" References: <46B4485B.7040406@menta.net> <46B454ED.700@philippewang.info><1186226538.14440.105.camel@rosella.wigram><46B48F3C.1040904@menta.net><1186242141.11801.10.camel@rosella.wigram><20070804162135.GA7370@furbychan.cocan.org><1186250087.6025.41.camel@rosella.wigram> <20070804191654.GI23762@furbychan.cocan.org> <000c01c7d77c$d5adeb50$6a7ba8c0@treble> <46B5FDA8.6060805@inria.fr> Subject: RE: [Caml-list] Sorted list Date: Sun, 5 Aug 2007 18:01:30 +0100 Organization: MetaStack Solutions Ltd. Message-ID: <000d01c7d782$459dac70$6a7ba8c0@treble> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 In-Reply-To: <46B5FDA8.6060805@inria.fr> Thread-Index: AcfXfaFG0nZKAXEDRdaTXBDid8jtEwAAhLAA X-Miltered: at discorde with ID 46B6026D.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; recursive:01 o'caml:01 stdlib:01 ocaml:01 recursion:01 constructors:01 compiler:01 trivial:01 compiler:01 hypothetical:01 o'caml:01 runtime:01 runtime:01 ocaml:01 assertion:01 > > its "tail recursive" implementations > > work by manipulating the internal representation of a list rather than > > writing "proper" O'Caml (it's a piece of genius and frankly is how the > > StdLib ought to do it...). > > I don't think so -- basically, Obj.magic isn't part of the OCaml > language and should not be used unless there is absolutely no other > option. The Queue module is the standard library uses Obj.magic for > additional performance, but this is really sending the wrong message. > If tail recursion elimination modulo constructors (what Extlib is > doing manually) is really important, I believe it should be done by > the compiler, under the hood. (That's not trivial, mind you.) Altering the compiler to do this would be the utopia, I agree - but if *you* (i.e. Inria) wrote an implementation using Obj.magic this doesn't send a bad message as such - the implementation of the Standard Library is *your* problem: as long as the module interface is the same, a hypothetical future version of O'Caml without Obj.magic could revert to the "slower" pure O'Caml implementations. Surely the standard library should aim to have the fastest implementation of these functions for any given version? Purely out of interest, how "standardised" are the primitives of the O'Caml runtime? Obj.magic may not be an official part of the language but what about the %identity primitive in the runtime? > I reluctantly but regularly use Windows to maintain the Windows port > of OCaml, and agree with Richard Jones's assessment. Windows is > geared towards the installation of big, standalone programs like > Office or games, but has nothing comparable to the package management > facilities of Linux or BSD. I completely agree that the Linux package management facilities are much more impressive (though I've never particularly missed them as there are other solutions for administration): but the assertion that Windows has nothing "to speak of" seemed somewhat ill-founded (and based back in 1993: cf. DOS 4/5 + Windows 3.0/3.1 which really didn't have any standard set-up features!). But this is possibly rather off-topic for this list/discussion... David