diff --git a/core/src/main/java/com/google/errorprone/bugpatterns/UnnecessarilyVisible.java b/core/src/main/java/com/google/errorprone/bugpatterns/UnnecessarilyVisible.java index 77a60f328d7..f09be5fe033 100644 --- a/core/src/main/java/com/google/errorprone/bugpatterns/UnnecessarilyVisible.java +++ b/core/src/main/java/com/google/errorprone/bugpatterns/UnnecessarilyVisible.java @@ -56,6 +56,8 @@ public final class UnnecessarilyVisible extends BugChecker implements MethodTree VisitorState.memoize( s -> Stream.of( + "com.google.errorprone.refaster.annotation.AfterTemplate", + "com.google.errorprone.refaster.annotation.BeforeTemplate", "com.google.inject.Inject", "com.google.inject.Provides", "com.google.inject.multibindings.ProvidesIntoMap", diff --git a/core/src/main/java/com/google/errorprone/bugpatterns/UnusedVariable.java b/core/src/main/java/com/google/errorprone/bugpatterns/UnusedVariable.java index 131dd46ca6f..153c4e02971 100644 --- a/core/src/main/java/com/google/errorprone/bugpatterns/UnusedVariable.java +++ b/core/src/main/java/com/google/errorprone/bugpatterns/UnusedVariable.java @@ -150,6 +150,8 @@ public final class UnusedVariable extends BugChecker implements CompilationUnitT // TODO(ghm): Find a sensible place to dedupe this with UnnecessarilyVisible. private static final ImmutableSet ANNOTATIONS_INDICATING_PARAMETERS_SHOULD_BE_CHECKED = ImmutableSet.of( + "com.google.errorprone.refaster.annotation.AfterTemplate", + "com.google.errorprone.refaster.annotation.BeforeTemplate", "com.google.inject.Inject", "com.google.inject.Provides", "com.google.inject.multibindings.ProvidesIntoMap",