From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id SAA07508 for caml-red; Wed, 8 Nov 2000 18:31:11 +0100 (MET) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id VAA02860 for ; Tue, 7 Nov 2000 21:03:29 +0100 (MET) Received: from mta6.snfc21.pbi.net (mta6.snfc21.pbi.net [206.13.28.240]) by nez-perce.inria.fr (8.11.1/8.10.0) with ESMTP id eA7K3Sv23050 for ; Tue, 7 Nov 2000 21:03:28 +0100 (MET) Received: from checkerlap.d6.com ([64.160.53.49]) by mta6.snfc21.pbi.net (Sun Internet Mail Server sims.3.5.2000.01.05.12.18.p9) with ESMTP id <0G3O00MIG4RGH2@mta6.snfc21.pbi.net> for caml-list@inria.fr; Tue, 7 Nov 2000 10:59:41 -0800 (PST) Date: Tue, 07 Nov 2000 11:03:16 -0800 From: Chris Hecker Subject: Re: anonymous function + lable bug? In-reply-to: <20001107115235U.garrigue@kurims.kyoto-u.ac.jp> X-Sender: def6@shell16.ba.best.com To: Jacques Garrigue Cc: caml-list@inria.fr Message-id: <4.3.2.7.2.20001107105936.00ac6710@shell16.ba.best.com> MIME-version: 1.0 X-Mailer: QUALCOMM Windows Eudora Version 4.3.2 Content-type: text/plain; charset="us-ascii" References: <4.3.2.7.2.20001105044616.00ababc0@shell16.ba.best.com> Sender: weis@pauillac.inria.fr >> I thought these two were equivalent? >They are not: Right, I didn't mean to say they're completely equivalent (I've read the FAQ), just that I expected equivalence in that case. >It would be possible to add special rules to allow > function ~l:p1 -> e1 | ... | ~l:pn -> en Ah, now I see, it's because the parameter in function is actually the pattern in an implicit match? Is there ever a reason to use function (assuming you don't mind parenthesizing constructors and whatnot in fun arguments)? Does the implied match allow some simplification or optimization or something? Why do they both exist? As I said, I've read the FAQ, but I can't see why you'd ever use function when you've got fun... Thanks, Chris