Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Equality of functional values
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Chris King <colanderman@g...>
Subject: Re: [Caml-list] Equality of functional values
Agreed.  Such a comparison is useful for libraries which must work
with arbitrary datatypes but want to compare as finely as possible.  I
once wrote a small pure-O'Caml module to do just that, you
can download it at  Caveat
emptor: it does not work on cyclic structures, and uses Obj
extensively so I cannot guarantee it won't crash.  It tries first
physical equality, then structural equality, so it is semantically
different from Caml's = operator in the case of floats.

- Chris

On 1/30/07, Jacques Carette <> wrote:
> Serious suggestion:  I personally would be quite happy with extensional
> equality on ground values and intensional equality on function values.
> Jacques
> _______________________________________________
> Caml-list mailing list. Subscription management:
> Archives:
> Beginner's list:
> Bug reports: