mirror of
https://github.com/clang-retro/llvm.git
synced 2026-11-28 13:19:18 -08:00
This migrates the remaining llvm-libc doc files to markdown.
The main concern I have is that there are still 6 eval-rst blocks
wrapping grid-tables, and native markdown tables have no way to
represent the colspan and rowspan cells in those files. In the end, I
decided to send this off as is, since it should have no visible
difference, and we can eliminate eval-rst later.
Migration notes from the agent:
- Restored underscore anchor labels such as `libc_gpu_rpc` because
rst2myst turned them into hyphenated names that other pages still
reference.
- Replaced Markdown links to Sphinx labels with `{ref}` roles because
plain links did not resolve to the labelled pages.
- Converted the flat grid tables in `headers/math/index.md` and
`headers/complex.md` to pipe tables using the `{{ check }}` substitution
because `|check|` is not defined inside `{eval-rst}` blocks.
- Kept the grid tables with row or column spans in
`headers/math/index.md`, `headers/math/log.md`, and `headers/stdfix.md`
inside narrowly scoped `{eval-rst}` blocks because pipe tables and
list-tables cannot express spans. Replaced `|check|` in the `stdfix.md`
tables with the check mark character, which matches the rendered
substitution.
- Restored the 57 `.. math::` blocks in `headers/math/log.md` as
`{math}` fences and turned default-role math into `{math}` roles because
rst2myst collapsed the multi-line equations and `$$` is not enabled.
- Kept the unused `.. role:: green` and `<style>` block in
`headers/math/index.md` because they were present in the source and
removing them is outside the scope of a markup migration.
- Changed "step a and step c" to "items 1 and 3" in
`headers/math/log.md` because Markdown has no alphabetic list markers,
so the lettered steps became numbered.
- Accepted single-backtick default-role text rendering as inline code
instead of italics in `headers/stdfix.md`, and empty table body cells
rendering with slightly more height in `uefi/support.md`, because those
are standard MyST rendering differences (visual diff 0.39% and 0.76%).
- Accepted nested list items in the "Edge cases" list of
`headers/math/log.md` now rendering inside their list items because the
original reST indentation left them outside, contrary to the evident
intent (visual diff 0.85%).
Tracking issue: #201242
See the [migration guide] for more information.
[migration guide]:
https://llvm.org/docs/SphinxQuickstartTemplate.html#markdown-migration-guidelines
This is a stacked PR based on #233687, which is a standalone commit that
renames *.rst -> *.md before this PR lands for history preservation
purposes.
This was prepared with rst2myst plus LLM-assisted cleanup.