Documentation fixes for the Quick Look and Parsing pages#999
Conversation
|
An automated preview of the documentation is available at https://999.url.prtest2.cppalliance.org/index.html If more commits are pushed to the pull request, the docs will rebuild at the same URL. 2026-05-13 22:32:27 UTC |
|
GCOVR code coverage report https://999.url.prtest2.cppalliance.org/gcovr/index.html Build time: 2026-05-13 22:45:27 UTC |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #999 +/- ##
========================================
Coverage 99.12% 99.12%
========================================
Files 154 154
Lines 10093 10093
========================================
Hits 10005 10005
Misses 88 88 Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
Closes #996, #997, #998.
Three small, self-contained fixes to the docs reported by the same author.
#996 —
u1.set_host(u2.host())example doesn't compiledoc/modules/ROOT/pages/quicklook.adocshowed:with
u1introduced as aurl_viewin the surrounding prose.url_viewis immutable, so the snippet doesn't compile. The example is a raw[source,cpp]block (not aninclude::of a tested snippet), so the fix is to make the freestanding code self-contained:u1is now aurl(mutable), which is whatset_hostrequires.#997 — encoded vs decoded segments produced the same output
In
quicklook.adoc, the "encoded segments" section claimed the loop prints:But the tested snippet asserts:
i.e. the actual library output is
my%2dfile.txt— the encoded form. The doc was showing the decoded string in the "encoded" block, making the two adjacent examples look identical. Updated the block to match what the snippet actually prints.#998 — "parses a string literal" intro didn't show the parse
doc/modules/ROOT/pages/urls/parsing.adocopened with:code_urls_parsing_1is only thestring_viewdeclaration — noparse_uricall. Further down the same page, the prose "The following two statements are equivalent:" was paired withcode_urls_parsing_2, which is a singleparse_uricall (not two statements at all). The blocks were transposed.Reorganised so the intro shows both
code_urls_parsing_1(string) andcode_urls_parsing_2(parse_uricall) in one fenced block — making the "parses a string literal" wording accurate — and the "two equivalent statements" section now correctly pairssnippet_parsing_3(r.value()) andsnippet_parsing_4(*r), which are the two equivalent ways to obtain theurl_viewfrom the result.Verified the Antora build (
doc/build_antora.sh) renders both blocks correctly.Follow-up: orphan snippets
While verifying #998 I ran a tags-defined vs tags-included comparison and found 112 snippet tags compiled and tested but never included in any page. Largest clusters:
snippet_parsing_path_*(22),snippet_parsing_authority_*(21),snippet_parsing_query_*(16),snippet_modifying_path_*(15). The kind of misalignment that produced #998 is structurally invisible today.Filed as a separate issue with a proposed CI lint to prevent regressions. Not in this PR's scope.