Documentation comments
These functions are used by the lexer to associate docstrings to the locations of tokens.
val set_pre_docstrings : Lexing.position ‑> docstring list ‑> unitDocstrings immediately preceding a token
val set_post_docstrings : Lexing.position ‑> docstring list ‑> unitDocstrings immediately following a token
val set_floating_docstrings : Lexing.position ‑> docstring list ‑> unitDocstrings not immediately adjacent to a token
val set_pre_extra_docstrings : Lexing.position ‑> docstring list ‑> unitDocstrings immediately following the token which precedes this one
val set_post_extra_docstrings : Lexing.position ‑> docstring list ‑> unitDocstrings immediately preceding the token which follows this one
The docs type represents documentation attached to an item.
val empty_docs : docsval docs_attr : docstring ‑> Ppxlib_ast__.Import.Parsetree.attributeval add_docs_attrs : docs ‑> Ppxlib_ast__.Import.Parsetree.attributes ‑> Ppxlib_ast__.Import.Parsetree.attributesConvert item documentation to attributes and add them to an attribute list
val symbol_docs : unit ‑> docsFetch the item documentation for the current symbol. This also marks this documentation (for ambiguity warnings).
val symbol_docs_lazy : unit ‑> docs Lazy.tval rhs_docs : int ‑> int ‑> docsFetch the item documentation for the symbols between two positions. This also marks this documentation (for ambiguity warnings).
val rhs_docs_lazy : int ‑> int ‑> docs Lazy.tval mark_symbol_docs : unit ‑> unitMark the item documentation for the current symbol (for ambiguity warnings).
val mark_rhs_docs : int ‑> int ‑> unitMark as associated the item documentation for the symbols between two positions (for ambiguity warnings)
The info type represents documentation attached to a field or constructor.
val empty_info : infoval info_attr : docstring ‑> Ppxlib_ast__.Import.Parsetree.attributeval add_info_attrs : info ‑> Ppxlib_ast__.Import.Parsetree.attributes ‑> Ppxlib_ast__.Import.Parsetree.attributesConvert field info to attributes and add them to an attribute list
The text type represents documentation which is not attached to anything.
val empty_text : textval empty_text_lazy : text Lazy.tval text_attr : docstring ‑> Ppxlib_ast__.Import.Parsetree.attributeval add_text_attrs : text ‑> Ppxlib_ast__.Import.Parsetree.attributes ‑> Ppxlib_ast__.Import.Parsetree.attributesConvert text to attributes and add them to an attribute list
val symbol_text_lazy : unit ‑> text Lazy.tval rhs_text_lazy : int ‑> text Lazy.tThere may be additional text attached to the delimiters of a block
(e.g. struct and end). This is fetched by the following
functions, which are applied to the contents of the block rather
than the delimiters.
val rhs_pre_extra_text : int ‑> textFetch additional text preceding the symbol at the given position
val rhs_post_extra_text : int ‑> textFetch additional text following the symbol at the given position