Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
mernst committed Aug 23, 2024
1 parent 283484e commit d4143f8
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ plugins {

// TODO: Java 23: remove this code block.
if (JavaVersion.current() <= JavaVersion.VERSION_22) {
apply plugin: 'net.ltgt.errorprone'
apply plugin: 'net.ltgt.errorprone'
}

repositories {
Expand Down Expand Up @@ -86,20 +86,20 @@ if (! isJava21orHigher) {

// TODO: Java 23: remove the "if" line" and corresponding "}"
if (JavaVersion.current() <= JavaVersion.VERSION_22) {
dependencies {
errorprone("com.google.errorprone:error_prone_core:${errorproneVersion}")
}
tasks.withType(JavaCompile).configureEach {
// "-processing" avoids javac warning "No processor claimed any of these annotations".
// "-Xlint:-options" is because of JDK 21 warning "source value 8 is obsolete..."
options.compilerArgs << '-Xlint:all,-processing,-options' << '-Werror'
options.errorprone {
// ExtendsObject does not yet exist in Error Prone 2.10.0.
// disable('ExtendsObject') // Incorrect when using the Checker Framework
disable('ReferenceEquality') // Use Interning Checker instead.
disable('AnnotateFormatMethod') // Error Prone doesn't know about Checker Framework @FormatMethod
dependencies {
errorprone("com.google.errorprone:error_prone_core:${errorproneVersion}")
}
tasks.withType(JavaCompile).configureEach {
// "-processing" avoids javac warning "No processor claimed any of these annotations".
// "-Xlint:-options" is because of JDK 21 warning "source value 8 is obsolete..."
options.compilerArgs << '-Xlint:all,-processing,-options' << '-Werror'
options.errorprone {
// ExtendsObject does not yet exist in Error Prone 2.10.0.
// disable('ExtendsObject') // Incorrect when using the Checker Framework
disable('ReferenceEquality') // Use Interning Checker instead.
disable('AnnotateFormatMethod') // Error Prone doesn't know about Checker Framework @FormatMethod
}
}
}
}

// Checker Framework pluggable type-checking
Expand Down Expand Up @@ -154,9 +154,9 @@ if (project.hasProperty('cfLocal')) {
}
// TODO: Java 23: remove this block.
if (JavaVersion.current() > JavaVersion.VERSION_22) {
checkerFramework {
skipCheckerFramework = true
}
checkerFramework {
skipCheckerFramework = true
}
}

// Javadoc
Expand Down

0 comments on commit d4143f8

Please sign in to comment.