Open GoogleCodeExporter opened 9 years ago
Can you add a testcase that reproduces this? With this code:
public void testRawProviderInjection() {
Guice.createInjector().getInstance(HasRawProvider.class);
}
private static class HasRawProvider {
@Inject HasRawProvider(Provider p) {}
}
I get:
com.google.inject.ConfigurationException: Guice configuration errors:
1) Cannot inject a Provider that has no type parameter
while locating com.google.inject.Provider
for parameter 0 at com.google.inject.InjectorTest$HasRawProvider.<init>(InjectorTest.java:419)
while locating com.google.inject.InjectorTest$HasRawProvider
1 error
at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1016)
at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:975)
at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1025)
at com.google.inject.InjectorTest.testRawProviderInjection(InjectorTest.java:415)
Original comment by sberlin
on 16 Oct 2011 at 4:20
Original issue reported on code.google.com by
crazybob...@gmail.com
on 27 May 2011 at 5:29