Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Weird Parser Error #117

Merged
merged 4 commits into from
Jan 23, 2025
Merged

fix: Weird Parser Error #117

merged 4 commits into from
Jan 23, 2025

Conversation

notJoon
Copy link
Contributor

@notJoon notJoon commented Jan 20, 2025

Description

This PR was originally supposed to be a Matcher feature implementation, but became a Another Parser Fix PR.

Fixes

  • Text scanning logic improvement Simplified the approach of checking text segments with character-by-character FSM transitions. Now it immediately closes and returns the text token when encountering boundary characters. This prevents issues of generating empty tokens or "no text found at position X" errors.
  • State transition table correction Modified transitions from text states (TX, WS) so that characters like :, [, ] transition to "metavariable/block start" states instead of error (ER) states. This enables proper text segment termination and continued metavariable parsing in expressions like "hello :[var]".

@notJoon notJoon added the T-fixer Type: Auto fix label Jan 20, 2025
@notJoon notJoon changed the title WIP Query matcher fix: Weird Parser Error Jan 23, 2025
@notJoon notJoon marked this pull request as ready for review January 23, 2025 10:35
@notJoon notJoon merged commit 52a25ff into main Jan 23, 2025
5 checks passed
@notJoon notJoon deleted the matcher branch January 23, 2025 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-fixer Type: Auto fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant