Skip to content
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

Explain match type reduction failures in error messages #12053

Merged
merged 9 commits into from
Apr 15, 2021

Conversation

odersky
Copy link
Contributor

@odersky odersky commented Apr 11, 2021

Fixes #12049

Also: Some tweaks for better printing

  • improve elision of package objects
  • don't print LazyRef nodes
  • fix display of match type cases that bind variables

Copy link
Contributor

@OlivierBlanvillain OlivierBlanvillain left a comment

Choose a reason for hiding this comment

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

LGTM!

@odersky odersky merged commit 104f437 into scala:master Apr 15, 2021
@odersky odersky deleted the fix-12049 branch April 15, 2021 11:13
OlivierBlanvillain added a commit to dotty-staging/dotty that referenced this pull request Apr 28, 2021
I suspect that the refactoring in scala#12053 turned scala#12050's infinite loop
into a stack overflow, which is easy to catch.

Although this doesn't completely fix the issue (we can't guarantee that
no stack-consuming loops exist), I think all the looping examples we
have so far error out gracefully.
michelou pushed a commit to michelou/scala3 that referenced this pull request May 1, 2021
I suspect that the refactoring in scala#12053 turned scala#12050's infinite loop
into a stack overflow, which is easy to catch.

Although this doesn't completely fix the issue (we can't guarantee that
no stack-consuming loops exist), I think all the looping examples we
have so far error out gracefully.
@Kordyjan Kordyjan added this to the 3.0.1 milestone Aug 2, 2023
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.

Match types could give better error diagnostics
3 participants