Skip to content

Various format/layout macros not converted across multiple files #27

@lefticus

Description

@lefticus

Problem

Multiple formatting and layout macros used for special typography are not being converted, appearing as raw LaTeX or causing layout issues.

Issues by Macro Type

1. \crange{} - Range notation not converted (time.md)

Line 7887:

\crange{69}{99}
\crange{00}{68}

Expected:

[69, 99]
[00, 68]

Count: 2 instances
Severity: Major


2. \fmtnontermdef{} - Grammar term definitions not converted (time.md)

Lines 7407, 7412, 7419, 7424, 7429, 7434:

Grammar productions showing raw \fmtnontermdef{name} instead of *name:*

Example:

\fmtnontermdef{chrono-format-spec}

Expected:

*chrono-format-spec:*

Count: 6 instances
Severity: Major


3. \texttt{} - Monospace formatting not converted

lex.md line 181:

| `U+005c` | reverse solidus | \texttt{\} |

Expected:

| `U+005c` | reverse solidus | `\` |

time.md line 7420:

\texttt{\}

Expected:

}

Count: 2 instances (lex.md: 1, time.md: 1)
Severity: Major


4. \terminal{} - Terminal symbol not converted (lex.md)

Line 360:

\terminal{R}

Expected:

'R' or R (as a terminal symbol)

Count: 1 instance
Severity: Major


5. \newline - Line breaks not converted in tables (lex.md)

Lines 1191-1195 (5 table rows):

| ... | array of $n$\newline `const char` | ... | `"ordinary string"`\newline `R"(ordinary raw string)"` |

Expected:

| ... | array of $n$<br>`const char` | ... | `"ordinary string"`<br>`R"(ordinary raw string)"` |

Count: 5 instances
Severity: Minor (table formatting)


6. \linebreak{} - Line break with extra braces (meta.md)

Line 968:

add_poin\linebreak{}ter_t

Expected:

add_pointer_t

(Or line break if appropriate)

Count: 1 instance
Severity: Major


7. LaTeX escape sequences in grammar (time.md)

Line 7420:

\{, \texttt{\}, \%

Expected:

{, }, %

Count: 3 escapes in one line
Severity: Major


8. \libheaderref{} - Header references in footnotes (future.md)

Lines 471-473, 818:

Header names completely missing from footnotes.

Current:

is declared in .

Expected:

is declared in `<cstring>`.

Count: 3 instances
Severity: Major


9. Implementation-defined not italicized (diagnostics.md)

Lines 1251, 1370, 1374, 1375, 1524:

using native_handle_type = implementation-defined

Expected:

using native_handle_type = *implementation-defined*

Count: 6 instances (5 wrong, 1 correct in prose)
Severity: Major

Impact

  • Severity: MAJOR overall (some individual instances are minor)
  • Multiple files affected with various formatting/layout issues
  • Makes code and tables harder to read
  • Inconsistent rendering across the document
  • Some cause actual content loss (header refs, line breaks)

Root Cause

Multiple filters need to handle these macros:

  • cpp-macros.lua - Most text macros
  • cpp-tables.lua - Table-specific formatting
  • cpp-grammar.lua - Grammar-specific macros
  • cpp-code-blocks.lua - Code block escapes

Recommendation

Add macro handling for each of these in the appropriate filter(s). Most are straightforward substitutions once identified.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingmajorMajor priority issue

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions