Browse thread
Represetation of data, and structural equality
[
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: | |
| Subject: | Represetation of data, and structural equality |
Dear Chet, Your question canot be answered in a theoretic framework: it depends on the compiler you use. In Caml V3.1 the answer is yes, in Caml Light the answer is no: > Caml Light version 0.5 #type foo = GOO of int;; Type foo defined. #let x = GOO 1;; x : foo = GOO 1 #let y = GOO 1;; y : foo = GOO 1 #x == y;; - : bool = false # CAML (decstation) (V3.1) by INRIA Thu Oct 15 #type foo = GOO of int;; Type foo is defined #let x = GOO 1;; Value x is (GOO 1) : foo #let y = GOO 1;; Value y is (GOO 1) : foo #x == y;; true : bool Pierre Weis ---------------------------------------------------------------------------- Formel Project INRIA, BP 105, F-78153 Le Chesnay Cedex (France) E-mail: Pierre.Weis@inria.fr Telephone: +33 1 39 63 55 98 ----------------------------------------------------------------------------