Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Consolidate compiler errors #62160

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

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Conversation

crisbeto
Copy link
Member

See the individual commits for more info, but the tl;dr is that these changes consolidate most of our compiler errors around ParseError so that it's easier to add more context to it in a follow-up.

crisbeto added 4 commits June 20, 2025 14:25
Currently we have a `ParserError` that is used for the expression parser and a `ParseError` that is used everywhere else. These changes consolidate them into the `ParseError` to avoid confusion and make it easier to add more context in the future.
Removes the `_ControlFlowError`, because its name is confusing and it's just a wrapper around `TokenError`.
Replaces the `TokenError` class with `ParseError` to reduce the number of error classes we need to maintain.
Removes the `I18nError` class since it wasn't being used for anything aside from a wrapper.
@crisbeto crisbeto added action: review The PR is still awaiting reviews from at least one requested reviewer target: patch This PR is targeted for the next patch release labels Jun 20, 2025
@angular-robot angular-robot bot added the area: compiler Issues related to `ngc`, Angular's template compiler label Jun 20, 2025
@ngbot ngbot bot added this to the Backlog milestone Jun 20, 2025
Replaces the `TranslationParseError` with `ParseError` since it wasn't adding much on top of `ParseError`.
@crisbeto crisbeto requested a review from AndrewKushnir June 20, 2025 18:49
@crisbeto crisbeto marked this pull request as ready for review June 20, 2025 18:49
Copy link
Contributor

@AndrewKushnir AndrewKushnir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the improvement @crisbeto 👍

@AndrewKushnir AndrewKushnir removed the action: review The PR is still awaiting reviews from at least one requested reviewer label Jun 20, 2025
@crisbeto
Copy link
Member Author

Passing TGP

@crisbeto crisbeto added the action: merge The PR is ready for merge by the caretaker label Jun 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
action: merge The PR is ready for merge by the caretaker area: compiler Issues related to `ngc`, Angular's template compiler target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants