From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id oBNFla3R010547 for ; Thu, 23 Dec 2010 16:47:36 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArEFAP79Ek1QW+UMgWdsb2JhbACVXjGOGRYBFiIkwTiFSgSLBIYS X-IronPort-AV: E=Sophos;i="4.60,219,1291590000"; d="scan'208";a="84639285" Received: from lo.gmane.org ([80.91.229.12]) by mail2-smtp-roc.national.inria.fr with ESMTP; 23 Dec 2010 16:47:30 +0100 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1PVnO4-0004LD-Ea for caml-list@inria.fr; Thu, 23 Dec 2010 16:47:28 +0100 Received: from avelizy-155-1-1-245.w83-199.abo.wanadoo.fr ([83.199.40.245]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 23 Dec 2010 16:47:28 +0100 Received: from sylvain by avelizy-155-1-1-245.w83-199.abo.wanadoo.fr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 23 Dec 2010 16:47:28 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: caml-list@inria.fr From: Sylvain Le Gall Date: Thu, 23 Dec 2010 15:47:17 +0000 (UTC) Message-ID: References: <20101217091950.GA28557@melkinpaasi.cs.helsinki.fi> X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: avelizy-155-1-1-245.w83-199.abo.wanadoo.fr User-Agent: slrn/pre1.0.0-18 (Linux) Subject: [Caml-list] Re: Unimplemented modules as top-level signatures Hello, On 23-12-2010, Lukasz Stafiniak wrote: > Interesting question. Lack of response on the mailing list means > agreement that this is an OK style? > I don't think so. Right now: 1) 3.12 is not yet used by everyone 2) its new features are still studied (at least by me) 3) style is really a matter of taste 4) it is in the language, so no problem using it So basically, go on, test it and give us your feedback. I doubt there are thousand people already using this, so you will define yourself what is right or wrong... AFAIC, I think it is great and that you should use it. > On Fri, Dec 17, 2010 at 10:19 AM, Lauri Alanko wrote: >> A minor annoyance in OCaml is that although you can (and must) put >> each top-level module into its own file, there is no corresponding >> mechanism for defining module types on their own: you always have to >> put a "module type" definition inside another module, which >> complicates scoping, and with standard tools adds an extra level of >> indentation to the signature definition. >> >> However, with 3.12 there is solution of sorts: write the signature >> definition in foo.mli without an accompanying foo.ml, and then refer >> to the signature as "module type of Foo". >> >> Is this horrible style? Are there some pitfalls I should be aware of? >> Or are there better solutions to my desire to avoid nested scoping? >> Top-level functors would also be nice to have... :) > > -- > Caml-list mailing list. Subscription management and archives: > https://sympa-roc.inria.fr/wws/info/caml-list > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > Bug reports: http://caml.inria.fr/bin/caml-bugs > > Regards, Sylvain Le Gall