Skip to content

Commit

Permalink
Remove {Lock,Unlock}MethodChecker.
Browse files Browse the repository at this point in the history
These have never been enabled, and the annotations they check are super rare. UnlockMethod seems to be checked by GuardedBy anyway.

PiperOrigin-RevId: 446965148
  • Loading branch information
graememorgan authored and Error Prone Team committed May 6, 2022
1 parent a7734bc commit 67fe479
Show file tree
Hide file tree
Showing 10 changed files with 6 additions and 609 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,12 @@
* <li><code>method-name()</code>: The lock object is returned by calling the named nullary
* method.
* </ul>
*
* @deprecated the correctness of this annotation is not enforced; it will soon be removed.
*/
@Target(METHOD)
@Retention(CLASS)
@Deprecated
public @interface LockMethod {
String[] value();
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,12 @@
* <li><code>method-name()</code>: The lock object is returned by calling the named nullary
* method.
* </ul>
*
* @deprecated the correctness of this annotation is not enforced; it will soon be removed.
*/
@Target(METHOD)
@Retention(CLASS)
@Deprecated
public @interface UnlockMethod {
String[] value();
}

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -500,11 +500,9 @@
import com.google.errorprone.bugpatterns.threadsafety.ImmutableChecker;
import com.google.errorprone.bugpatterns.threadsafety.ImmutableEnumChecker;
import com.google.errorprone.bugpatterns.threadsafety.ImmutableRefactoring;
import com.google.errorprone.bugpatterns.threadsafety.LockMethodChecker;
import com.google.errorprone.bugpatterns.threadsafety.StaticGuardedByInstance;
import com.google.errorprone.bugpatterns.threadsafety.SynchronizeOnNonFinalField;
import com.google.errorprone.bugpatterns.threadsafety.ThreadPriorityCheck;
import com.google.errorprone.bugpatterns.threadsafety.UnlockMethodChecker;
import com.google.errorprone.bugpatterns.time.DateChecker;
import com.google.errorprone.bugpatterns.time.DurationFrom;
import com.google.errorprone.bugpatterns.time.DurationGetTemporalUnit;
Expand Down Expand Up @@ -1051,7 +1049,6 @@ public static ScannerSupplier errorChecks() {
Java7ApiChecker.class,
Java8ApiChecker.class,
LambdaFunctionalInterface.class,
LockMethodChecker.class,
LongLiteralLowerCaseSuffix.class,
MemberName.class,
MethodCanBeStatic.class,
Expand Down Expand Up @@ -1101,7 +1098,6 @@ public static ScannerSupplier errorChecks() {
TypeParameterNaming.class,
TypeToString.class,
UngroupedOverloads.class,
UnlockMethodChecker.class,
UnnecessarilyFullyQualified.class,
UnnecessarilyVisible.class,
UnnecessaryAnonymousClass.class,
Expand Down
Loading

0 comments on commit 67fe479

Please sign in to comment.