Browse thread
Map.fold behavior changed
-
EEK Cooper
- Nathaniel Gray
- Jean-Christophe Filliatre
- Brian Hurt
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Jean-Christophe Filliatre <filliatr@l...> |
| Subject: | Re: [Caml-list] Map.fold behavior changed |
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" <http://caml.inria.fr/mantis/view.php?id=3607>, 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)