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

Confusing error messages when overload is missing but others are still there #554

Open
jrudolph opened this issue Sep 28, 2020 · 1 comment

Comments

@jrudolph
Copy link
Contributor

jrudolph commented Sep 28, 2020

As seen in akka/akka-http#3475.

In that case, an overload was replaced by a bunch of other ones. One of new ones matched the parameters but not the new return type which gave a IncompatibleResultTypeProblem. The others had different return type and parameter types which lead to another IncompatibleMethTypeProblem.

This is somewhat confusing since it reports errors from the viewpoint of the new methods when the compatibility problem in fact is "Overload in old version cannot be found in new version". IncompatibleResultTypeProblem and IncompatibleMethTypeProblem are basically more specific versions of that error that should be reported as one (for example: if there's only one overload, report whether result or parameter types have changed, if there are multiple overloads, just report that none of the overloads matches).

@dwijnand
Copy link
Collaborator

dwijnand commented Oct 8, 2020

I'll try your strategy, and see how it reflects in the testsuite.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants