Repository navigation
Fix #15276 (manual: improve the build) - #9079
Conversation
Lua filters, make-appendix.sh and the metadata files for the open source and premium manuals. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dmcppcheck
left a comment
There was a problem hiding this comment.
AI review
This PR only changes the documentation build: shell scripts, Lua pandoc filters and the CI workflow. No C/C++ code is touched. I found one new issue, and I could not confirm it because pandoc is not installed here. Some checker docs that are now pulled into the manual have unescaped <...> in prose. Pandoc reads these as raw HTML, so they vanish from the PDF and are hidden in the HTML. For example, the checkLibraryUseIgnore message would read "Function f() should have / configuration". Merging manual-premium.md into manual.md loses no text: diffing the new manual.md against the old manual-premium.md shows only the expected conditional blocks and the moved title/author. I found no other problems.
Comments
| # | Comment | By | Where | Status |
|---|---|---|---|---|
| 1 | Unescaped , , in included checker docs vanish from the manual | AI review | man/filters/manual.lua:150 |
🆕 New |
@danmar, please fix, resolve or reply to the open and new comments: #1.
Testing
- I didn't build cppcheck or run testrunner, because the PR changes no C/C++, GUI or test code.
- pandoc, xelatex, lua and shellcheck are not installed, so I could not build the manuals or run the Lua filters. Everything below about filter behaviour comes from reading the code.
sh -npasses onbuild-pdf.sh,build-html.sh,buildman.shandmake-appendix.sh../make-appendix.sh "Checkers" checkers/*.mdproduces 318included-fileDivs. All Div ids are unique, and no two checker file names differ only in case.- Every relative
*.mdlink insideman/checkerspoints to a file that exists, sodocument()inmanual.luacan resolve them all. None of these links has an anchor fragment. - I diffed
pr/man/manual.mdagainstbase/man/manual-premium.md. Apart from the title/author front matter, which moved to the yaml files, the only differences are thecontent-visiblewrappers: the opensource-onlymisra.pysection and the premium-only block at the end. So no premium content was lost. - Nothing else in the repo (CMake, release scripts, other workflows) refers to
manual-premium.mdor buildsmanual.md. - I scanned the checker docs for
<tag>text outside code blocks and inline code, ignoring<br/>:I could not render these, because pandoc is missing.checkers/checkLibraryUseIgnore.md:3: **Message**: --check-library: Function f() should have <use>/<leak-ignore> configuration<br/> checkers/leakUnsafeArgAlloc.md:3: **Message**: Unsafe allocation. If shared_ptr() throws, memory could be leaked. Use make_shared<T>() instead.<br/> checkers/unreadVariable.md:44: #include <mutex>
Automated review of b2deedc by Claude. The pull request was built and tested locally.
Pandoc treats <use>, <leak-ignore> and <T> as raw html and drops them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dmcppcheck
left a comment
There was a problem hiding this comment.
AI review
This PR only changes the documentation build: shell scripts, Lua pandoc filters, the buildman workflow and some checker docs. No C/C++ code is touched. I found no new problems. The earlier comment about <use>, <leak-ignore> and <T> in checker messages is fixed: both messages are now in backticks. The third example in that comment, #include <mutex> in unreadVariable.md, was already inside a fenced code block within a list item, so it was never affected. I could not render the manuals, because pandoc, LaTeX and Lua are not available in the container. Everything about the filters' behaviour below comes from reading the code.
Comments
| # | Comment | By | Where | Status |
|---|---|---|---|---|
| 1 | Unescaped , , in included checker docs are dropped as raw HTML | AI review | man/filters/manual.lua:150 |
✅ Fixed |
Testing
- I didn't build cppcheck or testrunner, because the PR changes no C/C++, GUI or test code.
- pandoc, xelatex, lua and shellcheck are not installed, so the manuals could not be built and the Lua filters could not be run.
- I scanned
man/checkers/*.mdfor<tag>text in prose, skipping fenced code, indented code and inline code. The only hit is#include <mutex>inunreadVariable.md:44, and that line is inside a fenced code block within a list item, so pandoc treats it as code. The two messages from the earlier comment are now in backticks. - Every checker doc starts with a
#heading exceptpremium-misra-config.md, which now starts with thecontent-visibleDiv. Its heading is still the first heading inside the Div, so the "first heading is numbered" logic inincluded_filestill works. - All relative links in the checker docs point to
*.mdfiles with no anchors. Afterinclude-files.luaprefixes them withcheckers/,file_id()inmanual.lua([^%w]→-) gives the same ids as thesed 's/[^A-Za-z0-9]/-/g'inmake-appendix.sh, so the links resolve to the included-file Divs. - No doc links to
premium-misra-config.md, so in the open source manual no link points to its now-empty Div. manual.mdhas only one internal anchor link (#the-error-element), and it is not inside the profile-conditional blocks.
Automated review of 853d338 by Claude. The pull request was built and tested locally.
No description provided.