From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id p5GGgqEo018624 for ; Thu, 16 Jun 2011 18:42:52 +0200 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AhMDAAQy+k3RVdQ2kGdsb2JhbAAnFQEDEpdphnsBh3UIFAEBAQEJCQ0HFAQhiHMlo1CMOoJHhE05iGYBAQMGhiEEgkKPF4tyPINK X-IronPort-AV: E=Sophos;i="4.65,376,1304287200"; d="scan'208";a="85535349" Received: from mail-vw0-f54.google.com ([209.85.212.54]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 16 Jun 2011 18:42:10 +0200 Received: by vws18 with SMTP id 18so2432077vws.27 for ; Thu, 16 Jun 2011 09:42:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=hn3ZvPWa6p163qiWHxv8tYd0G9CDuyAbC3n849uLsWk=; b=PFlmFf2iKRhVCBExemfwiZieFCo2ZxKeOpfbknfJO+XIZ6twmpUbUi+wzsEJf5KVKO T1FCOQW1Dtpms6SjzlEhpwlGMfJC5WJnFjnl/VE2hfYQZe+MNnOUuY7NTkoXum1ONw2u bYNj3tU/AGXk3AA1f6DKLEqAqpSew8Odnwf3Q= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; b=ELajRgETcQheHvqOFHUswg1wF5VHOlHXcHmVyhRI09thnHHe0OK4acSlrZJGGCZuUc Hl1QGc2mtgqpDVl2VXrlI4pLyU35kMoc5Ft+m1jwsKxEViLdQg6q+HqQZ5dUm7pXE0O/ P9S+C8UTEBurIsxL4CImzFIF8ajXWzYxDea8Q= Received: by 10.52.73.164 with SMTP id m4mr1425442vdv.157.1308241690094; Thu, 16 Jun 2011 09:28:10 -0700 (PDT) MIME-Version: 1.0 Received: by 10.52.170.11 with HTTP; Thu, 16 Jun 2011 09:27:50 -0700 (PDT) In-Reply-To: References: From: Gabriel Scherer Date: Thu, 16 Jun 2011 18:27:50 +0200 Message-ID: To: vincent.monfort@inria.fr Cc: caml-list@inria.fr Content-Type: multipart/alternative; boundary=bcaec501666f37ec2504a5d6c1c0 Subject: Re: [Caml-list] ocamldoc changes the names of polymorphic types --bcaec501666f37ec2504a5d6c1c0 Content-Type: text/plain; charset=ISO-8859-1 I don't think there is such an option. This is related, but not exactly the same as, this bugtracker entry: http://caml.inria.fr/mantis/view.php?id=5067 >From what I remember when posting the entry, ocamldoc has at its disposition both the parsed AST from the source, and the typedtree representation (the program representation after type inference). It uses the typedtree representation to display types, so I suppose the type variable name information is lost. You may change the output -- ocamldoc is rather modular and you can add plugins to change the output -- to use the parsed AST instead, which has the name information, but at the time I didn't find a way to do that easily without losing the nice syntax highlighting and cross-referencing performed by ocamldoc on the type. On Thu, Jun 16, 2011 at 6:02 PM, wrote: > Hi everyone, > I used particular names for some polymorphic types in my .mli files but > these > names were replaced with default names by ocamldoc in the documentation. > E.g.: > .mli: > type ('dom,'tf) manager = { > bot : 'dom; > ... > } > > .html: > type ('a, 'b) manager = { > bot : 'a; > ... > } > > Is there any way to force ocamldoc to keep the names given in the > documentation > ? > If it is not the case I think it would be a good thing because it could > make > the documentation more readable. > > Regards, > > Vincent > > -- > 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 > > --bcaec501666f37ec2504a5d6c1c0 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I don't think there is such an option.

This is related, but not = exactly the same as, this bugtracker entry:
=A0 http://caml.inria.fr/mantis/view.php?id= =3D5067

From what I remember when posting the entry, ocamldoc has at its dispos= ition both the parsed AST from the source, and the typedtree representation= (the program representation after type inference). It uses the typedtree r= epresentation to display types, so I suppose the type variable name informa= tion is lost. You may change the output -- ocamldoc is rather modular and y= ou can add plugins to change the output -- to use the parsed AST instead, w= hich has the name information, but at the time I didn't find a way to d= o that easily without losing the nice syntax highlighting and cross-referen= cing performed by ocamldoc on the type.

On Thu, Jun 16, 2011 at 6:02 PM, <vincent.monfort@in= ria.fr> wrote:
Hi everyone,
I used particular names for some polymorphic types in my .mli files but the= se
names were replaced with default names by ocamldoc in the documentation.
E.g.:
.mli:
type ('dom,'tf) manager =3D {
=A0bot : 'dom;
=A0...
}

.html:
type ('a, 'b) manager =3D {
=A0 =A0 =A0 =A0bot : 'a;
=A0 =A0 =A0 =A0...
}

Is there any way to force ocamldoc to keep the names given in the documenta= tion
?
If it is not the case I think it would be a good thing because it could mak= e
the documentation more readable.

Regards,

Vincent

--
Caml-list mailing list. =A0Subscription 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


--bcaec501666f37ec2504a5d6c1c0--