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=AWL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 081DEBC69 for ; Fri, 24 Aug 2007 02:20:05 +0200 (CEST) Received: from bsd4.nyct.net (mail-out8.nyct.net [216.139.141.8]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id l7O0K3Ce002050 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 24 Aug 2007 02:20:04 +0200 Received: from [192.168.42.2] (adsl-216-139-154-52.nyct.net [216.139.154.52]) by bsd4.nyct.net (8.13.4/8.13.4) with ESMTP id l7O0K1of063186 for ; Thu, 23 Aug 2007 20:20:02 -0400 (EDT) (envelope-from bhurt@spnz.org) Date: Thu, 23 Aug 2007 20:32:22 -0400 (EDT) From: Brian Hurt X-X-Sender: bhurt@localhost To: caml-list Subject: Stupid question re:modules Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Miltered: at concorde with ID 46CE2433.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; foo:01 sig:01 val:01 foo:01 sig:01 val:01 baz:01 baz:01 define:02 modules:02 defined:02 module:03 module:03 hints:04 types:05 I should just know this. So let's say I have two module types defined: module type Foo = sig type 'a t val foo : 'a -> 'a t end;; module type Bar = sig type 'a t val bar : 'a -> 'a t end;; Now, I want to define a module that is both a Foo and a Bar without cutting and pasting the module definitions around. I've been trying to do: module Baz : sig type 'a baz include Foo with type 'a t = 'a baz include Bar with type 'a t = 'a baz end;; but this blows up on the Bar line (multiple definitions of 'a t). There is a solution to this, I'm just being stupid and forgetting what it is. Hints would be appreciated. Brian