Closed shengc closed 9 years ago
Can you please include your guice module?
On Wed, Jun 10, 2015, 10:49 PM Mianwo notifications@github.com wrote:
class IntProvider extends Provider[Int] { def get() = 1 }
trait Foo[T] { def get() = T }
class FooProvider extends Provider[Foo[Long]] { def get() = new Foo[Long] { def get() = 1L } }
IntProvider is bound as java.lang.Object, and FooProvider is bound as Foo[java.lang.Object]. If instead I bind to the java primitives directly, types are right.
— Reply to this email directly or view it on GitHub https://github.com/codingwell/scala-guice/issues/48.
Sorry, this seems to be a very old issue without followup. This really is sporadic, and I cannot reproduce it any more.
Ok. Thanks for the update. Feel free to close this issue.
class IntProvider extends Provider[Int] { def get() = 1 }
trait Foo[T] { def get(): T }
class FooProvider extends Provider[Foo[Long]] { def get() = new Foo[Long] { def get() = 1L } }
IntProvider is bound as java.lang.Object, and FooProvider is bound as Foo[java.lang.Object]. If instead I bind to the java primitives directly, types are right.