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=1.0 required=5.0 tests=AWL,SPF_NEUTRAL autolearn=disabled version=3.1.3 Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 92550BC6B for ; Thu, 15 Mar 2007 15:48:47 +0100 (CET) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.249]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l2FEmkfh031137 for ; Thu, 15 Mar 2007 15:48:47 +0100 Received: by an-out-0708.google.com with SMTP id c24so178097ana for ; Thu, 15 Mar 2007 07:48:45 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Vv+vHMmkJWsnvXMsQiEc+MxLM2MM6AhLCqehPwLvgG1mEl7EfTWlo8bz/NAauHEfX/J+ayS6GzDRKiy82D3ifwbsNIzVPIs7xxuRjjMHsL+dqkK67Jx/2VMPwNwLBQlw0Y5cJYovqMYzKi2pa3e05T7JrYqGfxXg4MtElzH7K9U= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=WycMln39WIu21r9K1BHncKXNdFNuQZWrBWrNgDOCOCpBdhSkluHueuBl6brz2KqcbCDdf3C6AxSybGm/DhyFrAwZLLw5qxM3KhnaPRXsu1k/8RNpRMfis9PFtLUCw5osiFO+tGToO32YRSBmvLaOPCVYHC6z1DuXgZHIG/gwQyM= Received: by 10.114.72.1 with SMTP id u1mr253643waa.1173970124493; Thu, 15 Mar 2007 07:48:44 -0700 (PDT) Received: by 10.114.241.6 with HTTP; Thu, 15 Mar 2007 07:48:44 -0700 (PDT) Message-ID: <875c7e070703150748j74bd6bc2nb79150d4e095ab84@mail.gmail.com> Date: Thu, 15 Mar 2007 09:48:44 -0500 From: "Chris King" To: caml-list@yquem.inria.fr Subject: Re: [Caml-list] module types and constraints in several layers In-Reply-To: <20070315142142.GD3236@pc6197-c703.uibk.ac.at> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20070315101236.GB3236@pc6197-c703.uibk.ac.at> <875c7e070703150625r2fe44739r86755099a2bd2594@mail.gmail.com> <20070315142142.GD3236@pc6197-c703.uibk.ac.at> X-j-chkmail-Score: MSGID : 45F95CCE.000 on discorde : j-chkmail score : X : 0/20 1 0.000 -> 1 X-Miltered: at discorde with ID 45F95CCE.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; struct:01 sig:01 val:01 o'caml:01 wrote:01 caml-list:01 modules:02 constraints:03 constraints:03 types:03 types:03 module:03 module:03 fix:04 problem:05 On 3/15/07, Christian Sternagel wrote: > some.ml: > module Make (Trs : TRS.T) : SOME.T = struct This looks to be your problem... by specifying the type of Trs as TRS.T, you are losing the information about the relation between the types in the modules. You can fix this by adding this relation to the definition of TRS.T: module type T = sig type t module Term: TERM.T module Fun : FUNCTION.T with type t = Term.Fun.t val f0 : t -> Fun.t Setx.set end Otherwise O'Caml presumes Term and Fun to be completely unrelated. Hope this helps; module type constraints can get messy :)