Skip to content

Fix boolean initializer diagnostic location#401

Merged
Devon7925 merged 1 commit intomasterfrom
codex/fix-source-location-for-boolean-initializer-diagnostic
Oct 24, 2025
Merged

Fix boolean initializer diagnostic location#401
Devon7925 merged 1 commit intomasterfrom
codex/fix-source-location-for-boolean-initializer-diagnostic

Conversation

@Devon7925
Copy link
Copy Markdown
Owner

Summary

  • capture the initializer start position when parsing locals so diagnostics can use it
  • fall back to the initializer start when a boolean local reports a type mismatch without an expression location
  • assert the reported location in the boolean locals regression test

Testing

  • bun test test/booleans.test.ts --filter "boolean locals reject integer initializers"

https://chatgpt.com/codex/tasks/task_e_68fbd830b2b8832993d20cc1955fa4e7

@Devon7925 Devon7925 merged commit ff919fa into master Oct 24, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant