caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] On the equality of functional values
@ 2002-10-27 14:10 Alessandro Baretta
  2002-10-27 15:34 ` David Brown
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Alessandro Baretta @ 2002-10-27 14:10 UTC (permalink / raw)
  To: Ocaml

I have been experimenting with equal signs, and I noticed 
that the equality operator (=) behaves in a strange way with 
respect to functional values.

         Objective Caml version 3.06

# (=) = (=) ;;
Exception: Invalid_argument "equal: functional value".
# let x = (=) in x = x ;;
- : bool = true

The first line seems to imply that no comparisons are 
possible between functional values. However, the second line 
I typed does not raise the same exception. This seems to 
imply that comparisons are allowed between functional 
values, too.

Now, which of two hypotheses is correct?

Alex

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2002-10-29 10:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-27 14:10 [Caml-list] On the equality of functional values Alessandro Baretta
2002-10-27 15:34 ` David Brown
2002-10-27 17:58 ` David Monniaux
2002-10-28  6:15   ` Alessandro Baretta
2002-10-28  8:34     ` jeanmarc.eber
2002-10-29 10:32     ` Pierre Weis
2002-10-27 18:02 ` Remi VANICAT

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).