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

Inconsistent type-checking for implicits with inferred return type #10229

Open
scabug opened this Issue Mar 15, 2017 · 1 comment

Comments

Projects
None yet
1 participant
@scabug
Copy link

scabug commented Mar 15, 2017

An implicit with an inferred return type is (sometimes) visible before it's point of definition, despite the comments on #801.

Example in the wild is in specs2

  • a clean compile succeeds
  • an incremental compile that touches only that file fails
[error] specs2/matcher/src/main/scala/org/specs2/matcher/MatchResultMessages.scala:13: could not find implicit value for parameter mm: scalaz.Monoid[Product with Serializable with MatchResultMessages.this.MatchResultMessage]
[error]     Reducer.unitReducer { r: MatchResult[T] => r match {
[error]                         ^
[error] one error found
[error] (matcher/compile:compileIncremental) Compilation failed

See discussion on Scala contributors

@scabug

This comment has been minimized.

Copy link

scabug commented Mar 15, 2017

Imported From: https://issues.scala-lang.org/browse/SI-10229?orig=1
Reporter: @dragos
Affected Versions: 2.12.1
See #801

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