doc: qualify the @ref targets that named initialize - #106
Merged
Conversation
Six @ref targets naming initialize() resolved to something else, or to nothing, and MrDocs reports neither: an unresolved @ref is emitted as plain text, which looks exactly like a deliberate code span, and one that resolves to the wrong symbol renders as a confident link to the wrong page. `@ref registry::initialize`, in four places, names no page at all - MrDocs puts the member under registry-07/ and emits no initialize.adoc there - so all four rendered as an unlinked `registry::initialize` code span. `@ref initialize` on VptrFn::initialize and TypeHashFn::initialize resolved to the sibling member being documented, so each rendered as a self-link, `href="#"`, where the text promises the exception-safety section of the free function. Spell all six `@ref boost::openmethod::initialize`, the form already used in default_registry.hpp and macros.hpp, which resolves. Left alone deliberately: `@ref initialize` in TypeHashFn::hash_range, which self-scopes to TypeHashFn::initialize, and in fast_perfect_hash's `hash`, which self-scopes to that policy's own initialize. Both are right as they are - the sentence is about the policy's function, not the free one. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JQa4fuiwcfsheZYTCyfPPr
|
An automated preview of the documentation is available at https://106.openmethod.prtest3.cppalliance.org/libs/openmethod/doc/html/index.html If more commits are pushed to the pull request, the docs will rebuild at the same URL. 2026-09-12 14:32:01 UTC |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #106 +/- ##
===========================================
+ Coverage 93.46% 93.52% +0.05%
===========================================
Files 22 22
Lines 1653 1683 +30
Branches 500 508 +8
===========================================
+ Hits 1545 1574 +29
Misses 64 64
- Partials 44 45 +1
... and 2 files with indirect coverage changes Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
(Written by Claude Code, on behalf of @jll63.)
Six
@reftargets naminginitialize()resolved to something else, or to nothing. MrDocsreports neither case: an unresolved
@refis emitted as plain text, which looks exactly likea deliberate code span, and one that resolves to a real-but-wrong symbol renders as a
confident link to the wrong page. Nothing in the build catches either, so both survive
indefinitely.
@ref registry::initialize— four dead linksMrDocs puts the member under
registry-07/and emits noinitialize.adocthere, so thetarget does not exist and all four rendered as an unlinked
registry::initializecode span:initialize.hpp(onfinalize)boost/openmethod/finalize.adocpreamble.hpp(onVptrFn::initialize)policies/VptrFn/initialize.adocpreamble.hpp(onoutput)policies/output.adocpreamble.hpp(onstatic_vptr)registry-07/static_vptr.adoc@ref initialize— two self-linksOn
VptrFn::initializeandTypeHashFn::initializeit resolved to the sibling member beingdocumented, so each rendered as
href="#"— a link to the page you are already on — wherethe sentence promises the exception-safety section of the free function:
The fix
All six become
@ref boost::openmethod::initialize, the form already used indefault_registry.hppandmacros.hpp. Resolution is scope-relative, which is why the samespelling works unqualified at namespace scope and fails inside a class that has its own
initialize.Deliberately left alone
Two
@ref initializetargets self-scope correctly and are not touched:TypeHashFn::hash_range("Only valid after a call to...") andfast_perfect_hash'shash("the set passed to..."). Both sentences are about the policy's own function, not the free
one.
Verification
Rendered with
doc/build_antora.shand checked against the HTML, rather than read off thesource:
<a href="../../initialize.html" class="xref page"><code>boost::openmethod::initialize</code></a>;href="#"><code>initializeanywhere indoc/html/;registry::initializecode span anywhere indoc/html/;grep -rl MRDOCS doc/html/is empty.Two notes on things this PR does not change, both pre-existing:
interop_type_erasure.adoc(4) andmultiple_dispatch.adoc(1).grep -rn "\'" doc/modules/ROOT/pages/*.adoc, has two false positives ininterop_type_erasure.adoc: the ``` ``any``'s ``` double-backtick spelling renders correctly asany's`, and the following code span keeps itsformatting. The guard only anticipates the single-backtick form.
🤖 Generated with Claude Code
https://claude.ai/code/session_01JQa4fuiwcfsheZYTCyfPPr