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=1.4 required=5.0 tests=AWL,HTML_00_10,HTML_MESSAGE, SPF_NEUTRAL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 1604FBC0A for ; Mon, 29 Jan 2007 22:11:49 +0100 (CET) Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.171]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l0TLBmZj003311 for ; Mon, 29 Jan 2007 22:11:48 +0100 Received: by ug-out-1314.google.com with SMTP id q2so1470946uge for ; Mon, 29 Jan 2007 13:11:48 -0800 (PST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=dTTb2NFIiDvuHOgwpQa5akzwXo2WboePrmLbAFIA84k8bbh1eu4pIsi5kyN2JvKWmLJWkzBzOgdn9VhAt6swS8qbXVLerp1aQdGj3grL7wsW9nTibOqakjtAWerV8AqkcfsxB0R5mmjTgfZmuVRHcIudzvOzY1wDRo8lIQjkRkM= Received: by 10.82.107.15 with SMTP id f15mr4052464buc.1170105107564; Mon, 29 Jan 2007 13:11:47 -0800 (PST) Received: by 10.82.175.13 with HTTP; Mon, 29 Jan 2007 13:11:47 -0800 (PST) Message-ID: Date: Mon, 29 Jan 2007 22:11:47 +0100 From: Tom To: "Simon Frost" Subject: Re: [Caml-list] Equality of functional values Cc: "Caml List" In-Reply-To: <1170104645.4564.304.camel@penguin.local> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_128270_11526268.1170105107471" References: <1170104645.4564.304.camel@penguin.local> X-j-chkmail-Score: MSGID : 45BE6314.001 on discorde : j-chkmail score : X : 0/20 1 0.000 -> 1 X-Miltered: at discorde with ID 45BE6314.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; equality:01 equality:01 caml-list:01 functions:01 functions:01 functional:02 functional:02 guess:04 guess:04 structural:04 structural:04 mathematical:07 mathematical:07 definition:07 definition:07 X-Attachments: cset="UTF-8" cset="UTF-8" ------=_Part_128270_11526268.1170105107471 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline It's hard to perform equality on functional values, as it is hard to confirm two functions being the same... (even if you know the mathematical definition of the function, thus even harder if you only know the machine representation of it...). The best way around is to use == equality (= is structural equality, while == is referential equality - whether two names point to the same address in the memory), which might return false often, but will never fail on functional values. So I guess it's best you edit the source code (if you can) and change it... - Tom ------=_Part_128270_11526268.1170105107471 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline It's hard to perform equality on functional values, as it is hard to confirm two functions being the same... (even if you know the mathematical definition of the function, thus even harder if you only know the machine representation of it...). The best way around is to use == equality (= is structural equality, while == is referential equality - whether two names point to the same address in the memory), which might return false often, but will never fail on functional values. So I guess it's best you edit the source code (if you can) and change it...

- Tom
------=_Part_128270_11526268.1170105107471--