The previous Error Prone setup only properly worked on Java 8 and 9. By configuring Error Prone as a javac plugin it now also successfully runs on Java 10 and above. Running the plugin under Java 8 requires a modest amount of extra configuration.
While there:
Enable the ConstructorLeaksThis check now that the bug that was filed against it is fixed.
Drop the -Xlint:-processing flag because it seems the code now compiles fine without it.
This PR is on top of #31. @imTachu, for various reasons upgrading our internal build will require more work than what is shown here, but as you can see proper Java 10+ support is inching closer :).
NB: the work in this PR proved not quite trivial; I opened google/error-prone#1115 so that it may be easier for the next person to try this.
The previous Error Prone setup only properly worked on Java 8 and 9. By configuring Error Prone as a javac plugin it now also successfully runs on Java 10 and above. Running the plugin under Java 8 requires a modest amount of extra configuration.
While there:
ConstructorLeaksThis
check now that the bug that was filed against it is fixed.-Xlint:-processing
flag because it seems the code now compiles fine without it.This PR is on top of #31. @imTachu, for various reasons upgrading our internal build will require more work than what is shown here, but as you can see proper Java 10+ support is inching closer :).
NB: the work in this PR proved not quite trivial; I opened google/error-prone#1115 so that it may be easier for the next person to try this.