Skip to content

fix(parser): keep cross-references in initializers - #128

Merged
auscaster merged 1 commit into
mainfrom
fix/macro-initializer-refs
Aug 28, 2026
Merged

fix(parser): keep cross-references in initializers#128
auscaster merged 1 commit into
mainfrom
fix/macro-initializer-refs

Conversation

@auscaster

Copy link
Copy Markdown
Member

Fixes #127, reported by @gkodinov.

<initializer> was read as flat text, so every <ref> child was discarded. #define RETRY_HOOK registry->retry came out as #define RETRY_HOOK ->retry. Initializers now go through the same markdown conversion as every other field.

Macros gained initializer rendering in 2.1.13, so they have shown this since then. Variable initializers were affected for longer and are fixed by the same change.

On the follow-up about linking the reference: signatures render inside a ```cpp fence, where [baz](#baz) stays literal rather than becoming a link. The HTML in the issue is Doxygen's own output, which has no such constraint. So the reference is flattened to its text here, which is what makes the fence read correctly.

Covered by a fixture case in test/fixtures/macros plus unit tests for both the macro and variable paths.

Bundles the 2.1.15 bump, so merging releases it.

@auscaster
auscaster merged commit 80432d8 into main Aug 28, 2026
3 checks passed
@auscaster
auscaster deleted the fix/macro-initializer-refs branch August 28, 2026 07:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bad definition syntax in the latest moxygen 2.1.14 for #define's

1 participant