Skip to content

engine: take go-tex/math v0.25.0 (inline \def expands in the mouth) - #190

Merged
tannevaled merged 1 commit into
mainfrom
bump-math-def
Sep 2, 2026
Merged

engine: take go-tex/math v0.25.0 (inline \def expands in the mouth)#190
tannevaled merged 1 commit into
mainfrom
bump-math-def

Conversation

@tannevaled

Copy link
Copy Markdown
Contributor

Bumps go-tex/math v0.24.0 → v0.25.0 (go-tex/math#10), which expands a \def written inside a formula instead of dropping the equation.

Honest scope — a correctness bump, not a parity win

Measured across the 200 arXiv reference papers: output is byte-identical on all but one (2311.02037, +2 glyphs), no regression. That's expected — the engine's own math-macro retry already substitutes preamble- and body-level \def/\newcommand before the math layer runs, so only a \def appearing literally inside a formula's source reaches the new path, which the corpus essentially never does.

I verified the two papers whose skipped-count shifted by comparing rendered glyph output (the drop count is misleading): 2205.03780 is byte-identical (37 pages, 64,111 glyph-paths both ways); 2311.02037 gains 2 glyphs. Full engine suite green. Diff is go.mod/go.sum only.

Completes the lockstep for the \def library feature; I'm flagging the negligible corpus impact plainly rather than overclaiming.

🤖 Generated with Claude Code

v0.25.0 teaches the math layer to expand a \def written INSIDE a formula rather
than dropping the equation on the unknown command.

Honest scope: the measured corpus impact is negligible — across the 200 arXiv
reference papers, output is byte-identical on all but one (2311.02037, +2
glyphs), with no regression. That is expected: the engine's own math-macro
retry already substitutes preamble- and body-level \def/\newcommand before the
math layer runs, so only a \def appearing literally inside a formula's source —
which the corpus essentially never does — reaches this new path. This is a
correctness/robustness bump keeping the dependency current, not a parity win.

Verified: full engine suite green on v0.25.0; the two papers whose skipped-count
shifted were confirmed byte-identical (2205.03780) or a small real gain
(2311.02037) by comparing rendered glyph output, not the misleading drop count.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@tannevaled
tannevaled merged commit d08f5ff into main Sep 2, 2026
18 checks passed
@tannevaled
tannevaled deleted the bump-math-def branch September 2, 2026 17:20
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.

1 participant