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=2.8 required=5.0 tests=DNS_FROM_RFC_ABUSE, DNS_FROM_RFC_POST,DNS_FROM_RFC_WHOIS autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id EDAC6BC69 for ; Sat, 10 Mar 2007 06:33:35 +0100 (CET) Received: from web30508.mail.mud.yahoo.com (web30508.mail.mud.yahoo.com [68.142.200.121]) by concorde.inria.fr (8.13.6/8.13.6) with SMTP id l2A5XYZN009630 for ; Sat, 10 Mar 2007 06:33:35 +0100 Received: (qmail 63083 invoked by uid 60001); 10 Mar 2007 05:33:34 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=v7Jc2ogxj4WRYoVpqbGtU1F3GPaqrZxgvf25H8VFS2lWe0EGCy1anOlIPUA/pT76kWPWieFTvp9+R7MyfnVqBkEAghw/iOkojWnbohGxzj7pscOXtfxojmWzPiviTHk9cv0QoJHeA0VG8NsAdnJ5Khv/6rsj8Q1Hbvlf7dRJOnE= ; Message-ID: <20070310053334.63081.qmail@web30508.mail.mud.yahoo.com> X-YMail-OSG: BQLvNHEVM1nvO8fS63Vjb_qkk_9nwqlkllfaVbq0pvOguIBwTiZuOj0uBX7RkzTExcBkryPxTu4p.bYcONFU.dmi4OaGJRpRqCmkSirqyclsJMm1iEYwpkfjgAKh0snZ8VwNnD1xxGoqYlLMqP2aX6lYcg-- Received: from [216.157.192.71] by web30508.mail.mud.yahoo.com via HTTP; Fri, 09 Mar 2007 21:33:34 PST Date: Fri, 9 Mar 2007 21:33:34 -0800 (PST) From: David Thomas Subject: Re: [Caml-list] Operator overloading To: caml-list@yquem.inria.fr In-Reply-To: <4d5f7bec0703092108x78de8ca0s2e79451265281b61@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Miltered: at concorde with ID 45F2432E.002 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; overloading:01 pervasives:01 ambiguities:01 camlp:01 toolbar:98 toolbar:98 caml-list:01 defined:02 expression:02 expression:02 seems:03 seems:03 override:03 module:03 module:03 I rather like the idea proposed earlier of being able to say Module.(expression), where operators within that expression are drawn exclusively from Module (we can then say that the entire program is wrapped in an implicit Pervasives.() which seems somewhat elegant. It would allow cleaning up of complex mathematic expressions while not introducing ambiguities. It seems the biggest downside is some possibly unnecessary complexity. All of that said, I was not, prior to this discussion, aware that one could locally override operators already defined. I expect this to clean up a bit of my code when I get to applying it, and having done that I'll let you all know whether I feel it's sufficient or would still like to see the extension, for whatever it's worth (in which case, I'll get around to learning camlp4, I expect... :-p). ____________________________________________________________________________________ Never miss an email again! Yahoo! Toolbar alerts you the instant new Mail arrives. http://tools.search.yahoo.com/toolbar/features/mail/