-
Notifications
You must be signed in to change notification settings - Fork 91
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
DirectxLexer.py #247
DirectxLexer.py #247
Conversation
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
Could you please add tests for Static Token |
… PRs" This reverts commit 74178d8.
Hey, I didn't understand your request. Can you please elaborate? |
This pull request has been marked as stale because it has been inactive for more than 14 days. Please update this pull request or it will be automatically closed in 7 days. |
This pull request has been automatically closed because it has been inactive for more than 14 days. Please reopen if you still intend to submit this pull request. |
Summary
Corrected the regular expression patterns for the WHILE and DO tokens in the lexer to remove unnecessary escape characters. This ensures proper keyword matching and avoids tokenization errors.
Changes
Updated the WHILE pattern from r"\b\while\b" to r"\bwhile\b".
Updated the DO pattern from r"\b\do\b" to r"\bdo\b".
Testing
Manually tested the updated lexer with sample HLSL code containing while and do keywords to confirm correct tokenization.
Verified no other token patterns were affected.
Checklist