dagger icon indicating copy to clipboard operation
dagger copied to clipboard

Classes listed in injects aren't checked for completeness

Open gk5885 opened this issue 11 years ago • 0 comments

The following does not produce a compilation error:

@Module(injects = Foo.class)
public class TestModule {}

and

public class Foo {}

but throws the following exception at runtime:

Exception in thread "main" java.lang.IllegalStateException: Errors creating object graph:
  Unable to create binding for test.Foo required by class test.TestModule

It seems that completeness is checked for the dependencies of classes listed in injects, but not for the classes themselves.

gk5885 avatar Sep 30 '13 17:09 gk5885