Skip to main content

Module span

Module span 

Source
Expand description

Delimiter classification, recogniser error types, and per-region tagged spans.

The recogniser (super::scan::scan_math_regions) produces one super::MathRegion per recognised math region, each tagged with a MathSpan that records which delimiter family or environment introduced it plus the body byte range.

Unmatched openers and brace-imbalanced bodies become MathError values so the lint rules math/unbalanced-delim, math/unbalanced-env, and math/unbalanced-braces can surface a useful diagnostic without aborting the scan.

Structs§

MathBody
Math-body content with container prefixes hidden.

Enums§

AnyDelim
One of the four primitive math delimiter families.
DisplayDelim
Display delimiter pair carried on MathSpan::Display.
InlineDelim
Inline delimiter pair carried on MathSpan::Inline.
MathError
An unrecoverable shape the recogniser saw. The scanner never panics; it accumulates these and keeps scanning the rest of the document.
MathSpan
Per-region classification produced by the scanner.