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 Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 8C071BC0A for ; Thu, 24 May 2007 13:27:21 +0200 (CEST) Received: from hades.snarc.org (hades.snarc.org [212.85.152.11]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id l4OBRLwQ014968 for ; Thu, 24 May 2007 13:27:21 +0200 Received: by hades.snarc.org (Postfix, from userid 1000) id 06A111B4D7; Thu, 24 May 2007 13:22:27 +0200 (CEST) Date: Thu, 24 May 2007 13:22:26 +0200 To: skaller Cc: "Markus E.L." , caml-list@yquem.inria.fr Subject: Re: [Caml-list] Teaching bottomline, part 3: what should improve. Message-ID: <20070524112226.GA23569@snarc.org> References: <1179871823.6966.78.camel@Blefuscu> <1179875804.17533.33.camel@rosella.wigram> <20070523091909.GA8019@snarc.org> <46543875.9010305@janestcapital.com> <20070523214823.GA16180@snarc.org> <20070524083217.GA20963@snarc.org> <1180000262.10335.15.camel@rosella.wigram> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1180000262.10335.15.camel@rosella.wigram> X-Warning: Email may contain unsmilyfied humor and/or satire. User-Agent: Mutt/1.5.13 (2006-08-11) From: tab@snarc.org (Vincent Hanquez) X-Miltered: at concorde with ID 46557699.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; sig:01 struct:01 ocamlc:01 val:01 decl:01 decl:01 haskell:01 cheers:01 wrote:01 caml-list:01 int:01 int:01 module:03 ugly:03 let:03 On Thu, May 24, 2007 at 07:51:02PM +1000, skaller wrote: > Can't you can fix that by: > > module xx : sig .. end = struct > .. > end include xx > > That way all the symbols you want are in the .ml > file. Yes that would kind of work, however that generate an ugly signature with ocamlc -i (I know i'm beeing difficult here ;)) > However this isn't really the same as > > private val f: int -> int > let f x = .. > > which can be done by: > > let f (x:int):int = .. > > the problem being it is invasive (you have to > edit the function decl instead of writing a > separate type decl). I like the separation personally. Haskell has it, and I found it quite neat. Cheers, -- Vincent Hanquez