Skip to content

Commit

Permalink
Make PrivateModule#binder() non-final to allow binder customization i…
Browse files Browse the repository at this point in the history
…n subclasses. Fixes #1569 & fixes #1525. (The primary use-case for this is to override binder() to always call skipSources, like many AbstractModule impls.)

PiperOrigin-RevId: 525231256
  • Loading branch information
vlsi authored and Guice Team committed Apr 18, 2023
1 parent 22dca18 commit c3d8f51
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/com/google/inject/PrivateModule.java
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ protected final AnnotatedElementBuilder expose(TypeLiteral<?> type) {
// everything below is copied from AbstractModule

/** Returns the current binder. */
protected final PrivateBinder binder() {
protected PrivateBinder binder() {
checkState(binder != null, "The binder can only be used inside configure()");
return binder;
}
Expand Down

0 comments on commit c3d8f51

Please sign in to comment.