Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
* A signature that cannot be inhabited by any structures
@ 2007-09-08  7:54 Hyeonseung Im
  2007-09-08 11:39 ` [Caml-list] " Vincent Aravantinos
  0 siblings, 1 reply; 2+ messages in thread
From: Hyeonseung Im @ 2007-09-08  7:54 UTC (permalink / raw)
  To: caml-list

[-- Attachment #1: Type: text/plain, Size: 47 bytes --]

?)7/ :N:P@87N 18<:5H MIME G|=D@G 8^=CAv@T4O4Y.

[-- Attachment #2: Type: text/plain, Size: 627 bytes --]

Hi all.

 

I found something interesting. In the OCaml, the following signature is
valid. (I tested it with the OCaml version 3.09.2 and 3.10.0.)

 

(In the top-level)

# module type S = sig val x : int val x : float end;;

module type S = sig val x : int val x : float end

 

But, this module type seems not to be inhabited by any structures. On the
contrary, in the SML this sort of module types cannot be defined. (Actually,
it raises an error: the duplication of variables.)

 

I wonder if this is a feature of the OCaml (or maybe a bug in the
implementation).

I'd appreciate any comment on it.

 

Hyeonseung Im.

 


[-- Attachment #3: Type: text/html, Size: 3334 bytes --]

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

end of thread, other threads:[~2007-09-08 11:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-09-08  7:54 A signature that cannot be inhabited by any structures Hyeonseung Im
2007-09-08 11:39 ` [Caml-list] " Vincent Aravantinos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox