From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 13BFCBB81 for ; Fri, 24 Feb 2006 12:44:33 +0100 (CET) Received: from ext.lri.fr (ext.lri.fr [129.175.15.4]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id k1OBiWok028671 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 24 Feb 2006 12:44:32 +0100 Received: from smtp.lri.fr (serveur3-5 [129.175.3.5]) by ext.lri.fr (Postfix) with ESMTP id 895A4202688; Fri, 24 Feb 2006 12:44:32 +0100 (CET) Received: from pc9-152 (pc9-152 [129.175.9.152]) by smtp.lri.fr (Postfix) with ESMTP id 1A5CECED98; Fri, 24 Feb 2006 12:44:32 +0100 (CET) Received: from filliatr by pc9-152 with local (Exim 3.36 #1 (Debian)) id 1FCbMg-0004uZ-00; Fri, 24 Feb 2006 12:44:02 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <17406.61821.450737.625981@gargle.gargle.HOWL> Date: Fri, 24 Feb 2006 12:43:57 +0100 To: EEK Cooper Cc: caml-list@yquem.inria.fr Subject: Re: [Caml-list] Map.fold behavior changed In-Reply-To: <20060224112209.51szurk2dc00oggg@www.sms.ed.ac.uk> References: <20060224112209.51szurk2dc00oggg@www.sms.ed.ac.uk> X-Mailer: VM 7.19 under Emacs 21.4.1 From: Jean-Christophe Filliatre X-Virus-Scanned: by amavisd-new at lri.fr X-Miltered: at concorde with ID 43FEF1A0.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 filliatre:01 filliatr:01 lri:01 ocaml:01 ocaml:01 bug:01 unspecified:01 unspecified:01 filliatre:01 lri:01 filliatr:01 writes:01 caml:02 breaks:02 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.3 EEK Cooper writes: > > My team just noticed that the behavior of Map.fold changed in OCaml > version 3.08.4. > > I'm concerned that the OCaml team would change the behavior of a > library function so late in its life. I understand that it was thought > to be "wrong" , but > changing the behavior of an existing function breaks existing apps and > shouldn't be done lightly. I must agree with you since we also got a similar bug in one of our apps due to this Map.fold _implementation_ change. However, we must also admit that we were using an unspecified feature of the standard library. If I remember correctly, the documentation was saying that the traversal order was left _unspecified_. The new version of Map.fold simply has a stronger, but consistent, specification. From this point of view, the Ocaml team thus cannot be blamed. You (and I) were using the _implementation_ as a specification, which is bad :-) -- Jean-Christophe Filliātre (http://www.lri.fr/~filliatr)