From e486e49aba8d4c985b784f448617c9a84e6e6ddc Mon Sep 17 00:00:00 2001 From: Danno Ferrin Date: Thu, 11 Apr 2019 13:05:17 -0600 Subject: [PATCH] PIE-1505 - Build broken in Java 12 (#1263) There is one check that has issues in Java 12 and has yet to be fixed. Disable it when we detect we are being built on Java 12. --- build.gradle | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/build.gradle b/build.gradle index d64c21a19a..63be779a8c 100644 --- a/build.gradle +++ b/build.gradle @@ -172,6 +172,11 @@ allprojects { // Lazy impl causes excess CPU usage O(n) of non-final fiield when it should be O(1). check('FieldCanBeFinal', CheckSeverity.OFF) + // This check is broken in Java 12. See https://github.com/google/error-prone/issues/1257 + if ((JavaVersion.current().majorVersion as Integer) > 11) { + check('Finally', CheckSeverity.OFF) + } + check('InsecureCryptoUsage', CheckSeverity.WARN) check('WildcardImport', CheckSeverity.WARN) }