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

F-bounds of existential types aren't inferred #8198

Open
scabug opened this issue Jan 29, 2014 · 1 comment
Open

F-bounds of existential types aren't inferred #8198

scabug opened this issue Jan 29, 2014 · 1 comment

Comments

@scabug
Copy link

scabug commented Jan 29, 2014

Existential type bounds aren't inferred, a la #1786, when a bound is an F-bound. A modification of the example from #1786 which demonstrates:

abstract class SomeClass2[T] {def tValue: T}
class MyClass2[T <: SomeClass2[T]](val myValue:T)

def myMethod(i:MyClass2[_]) {
  i.myValue.tValue      // << error: value tValue is not a member of _$1
}

def myMethodT[T <: SomeClass2[T]](i:MyClass2[T]) {
  i.myValue.tValue      // << works
}

(I used to think this was part of #6169, but I do not think that now.)

@scabug
Copy link
Author

scabug commented Jan 29, 2014

Imported From: https://issues.scala-lang.org/browse/SI-8198?orig=1
Reporter: Stephen Compall (s11001001)
Affected Versions: 2.11.0-M8
See #1786

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

No branches or pull requests

2 participants