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.8 required=5.0 tests=AWL,INFO_TLD 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 7AA6CBC0B for ; Sat, 6 Jan 2007 16:37:31 +0100 (CET) Received: from 30.mail-out.ovh.net (30.mail-out.ovh.net [213.186.62.213]) by discorde.inria.fr (8.13.6/8.13.6) with SMTP id l06FbVnO021949 for ; Sat, 6 Jan 2007 16:37:31 +0100 Received: (qmail 13360 invoked by uid 503); 6 Jan 2007 15:37:45 -0000 Received: (QMFILT: 1.0); 06 Jan 2007 15:37:45 -0000 Received: from b6.ovh.net (HELO mail95.ha.ovh.net) (213.186.33.56) by 30.mail-out.ovh.net with SMTP; 6 Jan 2007 15:37:45 -0000 Received: from b0.ovh.net (HELO queue-out) (213.186.33.50) by b0.ovh.net with SMTP; 6 Jan 2007 15:37:36 -0000 Received: from vil93-4-82-227-140-227.fbx.proxad.net (HELO ?192.168.1.2?) (lists%philippewang.info@82.227.140.227) by ns0.ovh.net with SMTP; 6 Jan 2007 15:37:35 -0000 In-Reply-To: <17af13780701060722h363d2a2ep9defb458ecb17ab2@mail.gmail.com> References: <17af13780701060722h363d2a2ep9defb458ecb17ab2@mail.gmail.com> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=ISO-8859-1; format=flowed Message-Id: <065D28A1-37A8-4AC4-B2D0-EA3D5185A596@philippewang.info> Cc: caml-list@inria.fr Content-Transfer-Encoding: quoted-printable From: Philippe Wang Subject: Re: [Caml-list] annotating nested modules with ocamldoc Date: Sat, 6 Jan 2007 16:37:27 +0100 To: "Ian Zimmerman" X-Mailer: Apple Mail (2.752.2) X-Ovh-Remote: 82.227.140.227 (vil93-4-82-227-140-227.fbx.proxad.net) X-Ovh-Local: 213.186.33.20 (ns0.ovh.net) X-Miltered: at discorde with ID 459FC23B.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; ocamldoc:01 foo:01 mli:01 sig:01 val:01 foo:01 mli:01 sig:01 val:01 struct:01 ocamldoc:01 annotation:01 granularity:01 ocaml:01 cheers:01 Le 6 janv. 07 =E0 16:22, Ian Zimmerman a =E9crit : > Given the following files: > > (* Foo.mli *) > > module type BOO =3D sig > (** workaround: put documentation here *) > val boo : int -> int > end > > module Boo : BOO > > (* Foo.mli ends *) > > > > > (* Foo.ml *) > > let internal_goo i =3D i + 1 > > module type BOO =3D sig > val boo : int -> int > end > > module Boo : BOO =3D struct > let boo i =3D internal_goo (i + 1) > end > > (* Foo.ml ends *) > > > how do I produce an ocamldoc set *with* Foo.Boo.boo but *without* > Foo.internal_goo ? > > So far, the only way I've found is to only process the mli file with > ocamldoc and attach an annotation in the signature in the indicated > place, but that is awkward when I want to make a cross-reference (I > have to reference the signature instead of the structure). The > problem is that when processing a ml file, the granularity of what is > included is one of two extremes: either everything, or just stuff > that's declared in the corresponding mli file, and the latter by > definition excludes members of modules :-( I suggest you to use The Stop special comment (**/**) in the .ml file. (ocaml reference manual, section 15.2.2 ) Cheers, Philippe Wang mail(at)philippewang.info=