17d89f0a0SDavid Ostrovskyload( 27d89f0a0SDavid Ostrovsky "@bazel_tools//tools/jdk:default_java_toolchain.bzl", 37d89f0a0SDavid Ostrovsky "JDK9_JVM_OPTS", 47d89f0a0SDavid Ostrovsky "default_java_toolchain", 57d89f0a0SDavid Ostrovsky) 67d89f0a0SDavid Ostrovsky 77d89f0a0SDavid Ostrovskydefault_java_toolchain( 87d89f0a0SDavid Ostrovsky name = "error_prone_warnings_toolchain", 97d89f0a0SDavid Ostrovsky bootclasspath = ["@bazel_tools//tools/jdk:platformclasspath9.jar"], 107d89f0a0SDavid Ostrovsky jvm_opts = JDK9_JVM_OPTS, 117d89f0a0SDavid Ostrovsky package_configuration = [ 127d89f0a0SDavid Ostrovsky ":error_prone", 137d89f0a0SDavid Ostrovsky ], 147d89f0a0SDavid Ostrovsky visibility = ["//visibility:public"], 157d89f0a0SDavid Ostrovsky) 167d89f0a0SDavid Ostrovsky 177d89f0a0SDavid Ostrovsky# This EP warnings list borrowed from here: 187d89f0a0SDavid Ostrovsky# https://github.com/bazelbuild/BUILD_file_generator/blob/master/tools/bazel_defs/java.bzl 197d89f0a0SDavid Ostrovskyjava_package_configuration( 207d89f0a0SDavid Ostrovsky name = "error_prone", 217d89f0a0SDavid Ostrovsky javacopts = [ 227d89f0a0SDavid Ostrovsky "-XepDisableWarningsInGeneratedCode", 237d89f0a0SDavid Ostrovsky "-Xep:MissingCasesInEnumSwitch:ERROR", 247d89f0a0SDavid Ostrovsky "-Xep:ReferenceEquality:WARN", 257d89f0a0SDavid Ostrovsky "-Xep:StringEquality:WARN", 267d89f0a0SDavid Ostrovsky "-Xep:WildcardImport:WARN", 277d89f0a0SDavid Ostrovsky "-Xep:AmbiguousMethodReference:WARN", 287d89f0a0SDavid Ostrovsky "-Xep:BadAnnotationImplementation:WARN", 297d89f0a0SDavid Ostrovsky "-Xep:BadComparable:WARN", 307d89f0a0SDavid Ostrovsky "-Xep:BoxedPrimitiveConstructor:ERROR", 317d89f0a0SDavid Ostrovsky "-Xep:CannotMockFinalClass:WARN", 327d89f0a0SDavid Ostrovsky "-Xep:ClassCanBeStatic:WARN", 337d89f0a0SDavid Ostrovsky "-Xep:ClassNewInstance:WARN", 34*d54fc955SDavid Pursehouse "-Xep:DefaultCharset:ERROR", 357d89f0a0SDavid Ostrovsky "-Xep:DoubleCheckedLocking:WARN", 367d89f0a0SDavid Ostrovsky "-Xep:ElementsCountedInLoop:WARN", 377d89f0a0SDavid Ostrovsky "-Xep:EqualsHashCode:WARN", 387d89f0a0SDavid Ostrovsky "-Xep:EqualsIncompatibleType:WARN", 391f14c16aSDavid Pursehouse "-Xep:ExpectedExceptionChecker:ERROR", 407d89f0a0SDavid Ostrovsky "-Xep:Finally:WARN", 417d89f0a0SDavid Ostrovsky "-Xep:FloatingPointLiteralPrecision:WARN", 427d89f0a0SDavid Ostrovsky "-Xep:FragmentInjection:WARN", 437d89f0a0SDavid Ostrovsky "-Xep:FragmentNotInstantiable:WARN", 447d89f0a0SDavid Ostrovsky "-Xep:FunctionalInterfaceClash:WARN", 457d89f0a0SDavid Ostrovsky "-Xep:FutureReturnValueIgnored:WARN", 467d89f0a0SDavid Ostrovsky "-Xep:GetClassOnEnum:WARN", 477d89f0a0SDavid Ostrovsky "-Xep:ImmutableAnnotationChecker:WARN", 487d89f0a0SDavid Ostrovsky "-Xep:ImmutableEnumChecker:WARN", 497d89f0a0SDavid Ostrovsky "-Xep:IncompatibleModifiers:WARN", 507d89f0a0SDavid Ostrovsky "-Xep:InjectOnConstructorOfAbstractClass:WARN", 517d89f0a0SDavid Ostrovsky "-Xep:InputStreamSlowMultibyteRead:WARN", 527d89f0a0SDavid Ostrovsky "-Xep:IterableAndIterator:WARN", 537d89f0a0SDavid Ostrovsky "-Xep:JUnit3FloatingPointComparisonWithoutDelta:WARN", 547d89f0a0SDavid Ostrovsky "-Xep:JUnitAmbiguousTestClass:WARN", 557d89f0a0SDavid Ostrovsky "-Xep:LiteralClassName:WARN", 56f5d7f93bSDavid Pursehouse "-Xep:MissingFail:ERROR", 577d89f0a0SDavid Ostrovsky "-Xep:MissingOverride:WARN", 587d89f0a0SDavid Ostrovsky "-Xep:MutableConstantField:WARN", 597d89f0a0SDavid Ostrovsky "-Xep:NarrowingCompoundAssignment:WARN", 607d89f0a0SDavid Ostrovsky "-Xep:NonAtomicVolatileUpdate:WARN", 617d89f0a0SDavid Ostrovsky "-Xep:NonOverridingEquals:WARN", 627d89f0a0SDavid Ostrovsky "-Xep:NullableConstructor:WARN", 637d89f0a0SDavid Ostrovsky "-Xep:NullablePrimitive:WARN", 647d89f0a0SDavid Ostrovsky "-Xep:NullableVoid:WARN", 657d89f0a0SDavid Ostrovsky "-Xep:OperatorPrecedence:WARN", 667d89f0a0SDavid Ostrovsky "-Xep:OverridesGuiceInjectableMethod:WARN", 677d89f0a0SDavid Ostrovsky "-Xep:PreconditionsInvalidPlaceholder:WARN", 687d89f0a0SDavid Ostrovsky "-Xep:ProtoFieldPreconditionsCheckNotNull:WARN", 697d89f0a0SDavid Ostrovsky "-Xep:ProtocolBufferOrdinal:WARN", 707d89f0a0SDavid Ostrovsky "-Xep:RequiredModifiers:WARN", 717d89f0a0SDavid Ostrovsky "-Xep:ShortCircuitBoolean:WARN", 727d89f0a0SDavid Ostrovsky "-Xep:SimpleDateFormatConstant:WARN", 737d89f0a0SDavid Ostrovsky "-Xep:StaticGuardedByInstance:WARN", 747d89f0a0SDavid Ostrovsky "-Xep:SynchronizeOnNonFinalField:WARN", 757d89f0a0SDavid Ostrovsky "-Xep:TruthConstantAsserts:WARN", 767d89f0a0SDavid Ostrovsky "-Xep:TypeParameterShadowing:WARN", 777d89f0a0SDavid Ostrovsky "-Xep:TypeParameterUnusedInFormals:WARN", 787d89f0a0SDavid Ostrovsky "-Xep:URLEqualsHashCode:WARN", 797d89f0a0SDavid Ostrovsky "-Xep:UnsynchronizedOverridesSynchronized:WARN", 807d89f0a0SDavid Ostrovsky "-Xep:WaitNotInLoop:WARN", 817d89f0a0SDavid Ostrovsky ], 827d89f0a0SDavid Ostrovsky packages = ["error_prone_packages"], 837d89f0a0SDavid Ostrovsky) 847d89f0a0SDavid Ostrovsky 857d89f0a0SDavid Ostrovskypackage_group( 867d89f0a0SDavid Ostrovsky name = "error_prone_packages", 877d89f0a0SDavid Ostrovsky packages = [ 887d89f0a0SDavid Ostrovsky "//org.eclipse.jgit/...", 897d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.ant/...", 907d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.ant.test/...", 917d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.archive/...", 927d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.http.apache/...", 937d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.http.server/...", 947d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.http.test/...", 957d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.junit/...", 967d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.junit.http/...", 977d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.lfs/...", 987d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.lfs.server/...", 997d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.lfs.server.test/...", 1007d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.lfs.test/...", 1017d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.packaging/...", 1027d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.pgm/...", 1037d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.pgm.test/...", 1047d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.test/...", 1057d89f0a0SDavid Ostrovsky "//org.eclipse.jgit.ui/...", 1067d89f0a0SDavid Ostrovsky ], 1077d89f0a0SDavid Ostrovsky) 108