Skip to content

Commit

Permalink
docs: cpp-tagfiles is antora extension
Browse files Browse the repository at this point in the history
  • Loading branch information
alandefreitas committed Jul 23, 2024
1 parent 90ddc0b commit 65d3732
Show file tree
Hide file tree
Showing 8 changed files with 448 additions and 331 deletions.
4 changes: 4 additions & 0 deletions doc/antora.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,8 @@ ext:
command: node doc/generate-files.mjs
scan:
dir: doc/build/generated-files
cpp-tagfiles:
files:
- file: ./doc/tagfiles/boost-system-doxygen.tag.xml
base_url: https://www.boost.org/doc/libs/master/libs/system/doc/html/

424 changes: 424 additions & 0 deletions doc/lib/cpp-tagfiles.js

Large diffs are not rendered by default.

328 changes: 0 additions & 328 deletions doc/lib/cpp.js

This file was deleted.

2 changes: 1 addition & 1 deletion doc/local-playbook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ antora:
- require: '@antora/lunr-extension' # https://gitlab.com/antora/antora-lunr-extension
index_latest_only: true
- '@antora/collector-extension'
- require: ./lib/cpp-tagfiles.js
asciidoc:
attributes:
# Enable pagination
Expand All @@ -42,5 +43,4 @@ asciidoc:
remove-sidenav: ''
extensions:
- ./lib/boost-link-inline-macro.js
- ./lib/cpp.js
- '@asciidoctor/tabs'
2 changes: 1 addition & 1 deletion doc/modules/ROOT/pages/grammar/rules.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
= Parse Rules

A __Rule__ is an object which tries to match the beginning of an input character buffer against a particular syntax.
It returns a `result` containing a value if the match was successful, or an `error_code` if the match failed.
It returns a cpp:boost::system::result[] containing a value if the match was successful, or an `error_code` if the match failed.
Rules are not invoked directly.
Instead they are passed as values to a `parse` function, along with the input character buffer to process.
The first overload requires that the entire input string match, otherwise else an error occurs.
Expand Down
2 changes: 1 addition & 1 deletion doc/modules/ROOT/pages/quicklook.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ You can parse the string by calling this function:
include::example$unit/snippets.cpp[tag=code_urls_parsing_2,indent=0]
----

The function `parse_uri` returns an object of type ``result`<`url_view`>` which is a container resembling a variant that holds either an error or an object.
The function `parse_uri` returns an object of type cpp:result<url_view>[] which is a container resembling a variant that holds either an error or an object.
A number of functions are available to parse different types of URL.

We can immediately call `result::value` to obtain a `url_view`.
Expand Down
17 changes: 17 additions & 0 deletions doc/tagfiles/boost-system-doxygen.tag.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<tagfile>
<compound kind="file">
<name>boost/system/result</name>
<filename>system.html#ref_boostsystemresult_hpp</filename>
<namespace>boost::system</namespace>
</compound>
<compound kind="namespace">
<name>boost::system</name>
<filename></filename>
<class kind="class">boost::system::result</class>
</compound>
<compound kind="class">
<name>boost::system::result</name>
<filename>system.html#ref_resultt_e</filename>
</compound>
</tagfile>

0 comments on commit 65d3732

Please sign in to comment.