| Anonymous | Login | Signup for a new account | 2013-05-22 19:05 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||||
| 0004713 | OCaml | Camlp4 | public | 2009-02-10 20:20 | 2012-09-17 13:49 | ||||||
| Reporter | Yoric | ||||||||||
| Assigned To | dim | ||||||||||
| Priority | normal | Severity | minor | Reproducibility | always | ||||||
| Status | feedback | Resolution | open | ||||||||
| Platform | OS | OS Version | |||||||||
| Product Version | 3.11.0 | ||||||||||
| Target Version | 4.01.0+dev | Fixed in Version | |||||||||
| Summary | 0004713: Camlp4o messes with comments | ||||||||||
| Description | Camlp4o messes with comments, hence with ocamldoc generation of documentation. In order for comments to be used by ocamldoc, they should come immediately before or after a value. Camlp4o moves comments away from values, hences breaks ocamldoc. While there may be workarounds, it's quite annoying for documentation generation of Batteries Included, as it produces pages such as http://batteries.forge.ocamlcore.org/doc.preview:batteries-alpha3/html/api/GZip.html [^] . Is there any hope that this could be fixed? | ||||||||||
| Tags | No tags attached. | ||||||||||
| Attached Files | |||||||||||
Relationships |
|||||||||||
|
|||||||||||
Notes |
|
|
(0004835) Yoric (reporter) 2009-02-10 20:22 |
camlp4o t.mli => the comment is removed |
|
(0004836) Yoric (reporter) 2009-02-10 20:22 |
camlp4o t2.mli => the first comment is moved from the first value to the second value, the second comment is removed |
|
(0005216) ygrek (reporter) 2009-12-31 13:50 |
camlp4.diff - a dirty workaround that will partially fix observed behaviour (for interface files). Can't think of anything better unless comments become part of the Ast (why not?). |
|
(0005692) ygrek (reporter) 2010-10-27 16:26 |
Here is one more example : http://extunix.forge.ocamlcore.org/api/ExtUnixSpecific.html#TYPEadvice [^] Is it possible to make comments part of the AST and will you consider such patch for inclusion? |
|
(0006597) dim (developer) 2012-01-05 12:01 |
Note that the problem is that you are using an intermediate on-disk file, camlp4 is not supposed to be used like this (you loose locations for example). If you call ocamldoc on the file before it is preprocessed with the right -pp option, then the result is fine (i tried for extunix). A possible solution for extunix is to copy extUnix.mlpp to extUnixAll.ml and extUnixSpecific.ml and use camlp4 on both files. If you want i can provide a patch. |
|
(0006601) ygrek (reporter) 2012-01-05 16:38 |
Thanks for looking into it - I will try to generate docs with simultaneous preprocessing and see how it goes. The generated files are included in distribution so I decided to generate docs from that files without much thinking. (Anyway, camlp4 ideally shouldn't mess with comments). |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2009-02-10 20:20 | Yoric | New Issue | |
| 2009-02-10 20:20 | Yoric | File Added: t.mli | |
| 2009-02-10 20:22 | Yoric | Note Added: 0004835 | |
| 2009-02-10 20:22 | Yoric | Note Added: 0004836 | |
| 2009-03-28 17:19 | xleroy | Status | new => assigned |
| 2009-03-28 17:19 | xleroy | Assigned To | => ertai |
| 2009-12-31 13:44 | ygrek | File Added: camlp4.diff | |
| 2009-12-31 13:50 | ygrek | Note Added: 0005216 | |
| 2010-10-27 16:26 | ygrek | Note Added: 0005692 | |
| 2011-10-26 08:44 | ertai | Assigned To | ertai => xclerc |
| 2012-01-05 12:01 | dim | Note Added: 0006597 | |
| 2012-01-05 12:01 | dim | Assigned To | xclerc => dim |
| 2012-01-05 12:01 | dim | Status | assigned => feedback |
| 2012-01-05 16:38 | ygrek | Note Added: 0006601 | |
| 2012-07-11 14:58 | doligez | Target Version | => 4.01.0+dev |
| 2012-07-11 15:52 | doligez | Relationship added | related to 0004545 |
| 2012-07-11 16:06 | doligez | Relationship added | related to 0004346 |
| 2012-07-31 13:36 | doligez | Target Version | 4.01.0+dev => 4.00.1+dev |
| 2012-09-17 13:49 | doligez | Target Version | 4.00.1+dev => 4.01.0+dev |
| Copyright © 2000 - 2011 MantisBT Group |