Skip to content

fix: hex strings misparsed after non-string meta values - #294

Merged
PeterMatula merged 1 commit into
masterfrom
fix/hex-string-after-non-string-meta
Jul 23, 2026
Merged

fix: hex strings misparsed after non-string meta values#294
PeterMatula merged 1 commit into
masterfrom
fix/hex-string-after-non-string-meta

Conversation

@PeterMatula

Copy link
Copy Markdown
Collaborator

When the last value in a meta: section was an integer or boolean, the lexer stayed in the $meta state at the strings keyword. The $meta-state strings token transitioned back to @default but, unlike its @default counterpart, never set sectionStrings(true) -- so a following { was not recognized as a hex string opener and its nibbles were lexed as integers, causing a ParserError. A trailing string meta value masked the bug because the closing quote already returns the lexer to @default.

Also sets sectionStrings(false) on the $meta-state condition token to mirror the @default counterpart. Adds C++ and Python regression tests.

When the last value in a meta: section was an integer or boolean, the
lexer stayed in the $meta state at the strings keyword. The $meta-state
strings token transitioned back to @default but, unlike its @default
counterpart, never set sectionStrings(true) -- so a following { was not
recognized as a hex string opener and its nibbles were lexed as
integers, causing a ParserError. A trailing string meta value masked the
bug because the closing quote already returns the lexer to @default.

Also sets sectionStrings(false) on the $meta-state condition token to
mirror the @default counterpart. Adds C++ and Python regression tests.

Co-Authored-By: Claude <noreply@anthropic.com>
@PeterMatula
PeterMatula merged commit 25bf7cc into master Jul 23, 2026
15 checks passed
@PeterMatula
PeterMatula deleted the fix/hex-string-after-non-string-meta branch July 23, 2026 11:16
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.

2 participants