mirror of
https://github.com/HKUDS/DeepTutor.git
synced 2026-12-02 17:09:29 +08:00
parse() swallowed a `[^token]` that was part of an entry's text. The new-bullet regex matched trailing markers as `[^...]` (any non-`]` run), so prose ending in a footnote-like token (e.g. "footnote syntax is [^note]") was absorbed into the markers group and dropped, breaking the documented `parse(serialize(d)) == d` contract. Because the token label failed to resolve, the text was silently truncated and, once the entry also carried a real ref, its markers were mangled too. serialize() emits integer labels exclusively, so narrow the inline-marker pattern to `[^<digits>]`. Non-integer footnote-like tokens now stay in the text where they belong; real numeric citation markers still parse (including the legacy compact `[^1][^2]` form). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>