From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id E773EBC6B for ; Tue, 15 May 2007 12:22:18 +0200 (CEST) Received: from decis.be (157.219-78-194.adsl-static.isp.belgacom.be [194.78.219.157]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l4FAMIDQ010528 for ; Tue, 15 May 2007 12:22:18 +0200 Received: from [192.168.0.30] by decis.be (MDaemon.PRO.v8.1.3.R) with ESMTP id md50000730021.msg for ; Tue, 15 May 2007 12:21:49 +0200 Message-ID: <464989BB.3040307@decis.be> Date: Tue, 15 May 2007 12:21:47 +0200 From: =?ISO-8859-1?Q?Fr=E9d=E9ric_van_der_Plancke?= User-Agent: Thunderbird 1.5.0.10 (Windows/20070221) MIME-Version: 1.0 To: caml-list@yquem.inria.fr Subject: Re: [Caml-list] Polymorphic variant difference... References: <20070514100005.459F6BC70@yquem.inria.fr><002c01c79615$e9750b30$6a7ba8c0@treble> <20070515.134054.08075760.garrigue@math.nagoya-u.ac.jp> <001601c796d5$b723b6c0$6a7ba8c0@treble> In-Reply-To: <001601c796d5$b723b6c0$6a7ba8c0@treble> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Authenticated-Sender: fplancke@decis.be X-MDRemoteIP: 192.168.0.30 X-Return-Path: fvdp@decis.be X-MDaemon-Deliver-To: caml-list@yquem.inria.fr Reply-To: fvdp@decis.be X-Miltered: at discorde with ID 464989DA.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; plancke:01 foo:01 mli:01 foo:01 mli:01 sig:01 struct:01 sig:01 polymorphic:01 wrote:01 wrote:01 caml-list:01 variant:02 seems:03 types:03 David Allsopp wrote: > ** Furthermore, I can't even hide these redundant types in the > implementation: > > Foo.mli > > type t = [ `A | `B ] > > Foo.ml > > type t' = [ `A ] > type t = [ `A | t' ] > > Is not valid even though t is /effectively/ the same p-variant in both the > .mli and .ml > That's maybe just because of a typo (you wrote `A for `B below) ? This seems to works with 3.09: # module M : sig type t = [ `A | `B ] end = struct type t' = [`A] type t = [`B | t' ] end;; module M : sig type t = [ `A | `B ] end Frédéric