summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCole Faust <colefaust@google.com>2022-10-15 21:33:29 -0700
committerCole Faust <colefaust@google.com>2022-10-15 21:33:29 -0700
commitbbab10c64b24e771597dce8ccfd7f5ffee6bb7c1 (patch)
tree66c2087e543780e82b4ef256aae026da96dcf996
parent2070d50c31d77a29746a080be684b7d977d5d3c4 (diff)
downloadapache-commons-math-bbab10c64b24e771597dce8ccfd7f5ffee6bb7c1.tar.gz
Fix errorprone warnings that should be errors
This commit is part of a large scale change to fix errorprone errors that have been downgraded to warnings in the android source tree, so that they can be promoted to errors again. The full list of changes include the following, but not all will be present in any one individual commit: BadAnnotationImplementation BadShiftAmount BanJNDI BoxedPrimitiveEquality ComparableType ComplexBooleanConstant CollectionToArraySafeParameter ConditionalExpressionNumericPromotion DangerousLiteralNull DoubleBraceInitialization DurationFrom DurationTemporalUnit EmptyTopLevelDeclaration EqualsNull EqualsReference FormatString FromTemporalAccessor GetClassOnAnnotation GetClassOnClass HashtableContains IdentityBinaryExpression IdentityHashMapBoxing InstantTemporalUnit InvalidTimeZoneID InvalidZoneId IsInstanceIncompatibleType JUnitParameterMethodNotFound LockOnBoxedPrimitive MathRoundIntLong MislabeledAndroidString MisusedDayOfYear MissingSuperCall MisusedWeekYear ModifyingCollectionWithItself NoCanIgnoreReturnValueOnClasses NonRuntimeAnnotation NullableOnContainingClass NullTernary OverridesJavaxInjectableMethod ParcelableCreator PeriodFrom PreconditionsInvalidPlaceholder ProtoBuilderReturnValueIgnored ProtoFieldNullComparison RandomModInteger RectIntersectReturnValueIgnored ReturnValueIgnored SelfAssignment SelfComparison SelfEquals SizeGreaterThanOrEqualsZero StringBuilderInitWithChar TreeToString TryFailThrowable UnnecessaryCheckNotNull UnusedCollectionModifiedInPlace XorPower See https://errorprone.info/bugpatterns for more information on the checks. Bug: 253827323 Test: m RUN_ERROR_PRONE=true javac-check Change-Id: Ia7232492b71f2c516dee6b56ed3226dbb6733da1
-rw-r--r--Android.bp6
1 files changed, 5 insertions, 1 deletions
diff --git a/Android.bp b/Android.bp
index 11252fc..ac41b9c 100644
--- a/Android.bp
+++ b/Android.bp
@@ -58,7 +58,11 @@ java_library {
srcs: ["src/main/java/**/*.java"],
sdk_version: "current",
errorprone: {
- javacflags: ["-Xep:MissingOverride:OFF"],
+ javacflags: [
+ "-Xep:MissingOverride:OFF",
+ "-Xep:IdentityBinaryExpression:OFF",
+ "-Xep:BoxedPrimitiveEquality:OFF",
+ ],
},
}