Skip to content

Add span information for action code, improve errors.#625

Merged
ltratt merged 1 commit intosoftdevteam:masterfrom
ratmice:issue_623
Mar 3, 2026
Merged

Add span information for action code, improve errors.#625
ltratt merged 1 commit intosoftdevteam:masterfrom
ratmice:issue_623

Conversation

@ratmice
Copy link
Collaborator

@ratmice ratmice commented Mar 3, 2026

This adds span information for rust action code in yacc files to the ast. This subsequently gets added to YaccGrammar then used for an error message in CTParserBuilder.

This is kind of just a first attempt, not a full audit of errors in CTParserBuilder.
I did some light testing by modifying the calc_actions example, but it'd be good to test with a real world example.

Note: I did have to do a clean rebuild of this because it changes the bincode encoding of the YaccGrammar struct

This adds span information for rust action code in yacc files to the ast.
This subsequently gets added to `YaccGrammar` then used for an error message
in `CTParserBuilder`.
@ltratt
Copy link
Member

ltratt commented Mar 3, 2026

This looks like a good start -- thanks!

@ltratt ltratt added this pull request to the merge queue Mar 3, 2026
Merged via the queue into softdevteam:master with commit b95668e Mar 3, 2026
2 checks passed
ratmice added a commit to ratmice/grmtools that referenced this pull request Mar 3, 2026
@ratmice ratmice deleted the issue_623 branch March 4, 2026 14:03
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