Commits
Click on a commit to change the comparison rangefeat(ast): add keyword and operator position fields to AST nodes
Add `u32` position fields for keywords and punctuators where the position
cannot be derived from `span.start`. This improves:
- Linter fix accuracy
- Formatter comment placement
- Diagnostic accuracy in parser, semantic, and linter
## Changes
### Core Statements
- `IfStatement`: `else_pos: Option<u32>`
- `TryStatement`: `catch_pos: Option<u32>`, `finally_pos: Option<u32>`
- `DoWhileStatement`: `while_pos: u32`
- `ForInStatement`: `in_pos: u32`
- `ForOfStatement`: `of_pos: u32`
- `SwitchCase`: `keyword_pos: u32`
### Operators
- `BinaryExpression`: `operator_pos: u32`
- `LogicalExpression`: `operator_pos: u32`
- `AssignmentExpression`: `operator_pos: u32`
- `PrivateInExpression`: `in_pos: u32`
### Other Expressions
- `ConditionalExpression`: `question_pos: u32`, `colon_pos: u32`
- `ArrowFunctionExpression`: `arrow_pos: u32`
### TypeScript Nodes
- `TSConditionalType`: `extends_pos: u32`, `question_pos: u32`, `colon_pos: u32`
- `TSAsExpression`: `as_pos: u32`
- `TSSatisfiesExpression`: `satisfies_pos: u32`
- `TSMappedType`: `in_pos: u32`
All position fields are marked with `#[content_eq(skip)]` and `#[estree(skip)]`
to exclude them from content equality comparisons and ESTree output.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>