Skip to content

Commit

Permalink
Improve Javadoc and consistently use SourceVersion.latest().
Browse files Browse the repository at this point in the history
  • Loading branch information
christian-schlichtherle authored and rspilker committed Jan 15, 2021
1 parent 4f36080 commit 648a56c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/core/lombok/core/AnnotationProcessor.java
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ static abstract class ProcessorDescriptor {
private final List<String> delayedWarnings = new ArrayList<String>();

/**
* This method is a simplified version of {@link lombok.javac.apt.LombokProcessor.getJavacProcessingEnvironment}
* This method is a simplified version of {@link lombok.javac.apt.LombokProcessor#getJavacProcessingEnvironment}
* It simply returns the processing environment, but in case of gradle incremental compilation,
* the delegate ProcessingEnvironment of the gradle wrapper is returned.
*/
Expand Down Expand Up @@ -120,7 +120,7 @@ private static Object tryGetProcessingEnvField(Class<?> delegateClass, Object in
}

/**
* InteliJ >= 2020.3
* IntelliJ IDEA >= 2020.3
*/
private static Object tryGetProxyDelegateToField(Class<?> delegateClass, Object instance) {
try {
Expand Down Expand Up @@ -257,6 +257,6 @@ static class EcjDescriptor extends ProcessorDescriptor {
* We just return the latest version of whatever JDK we run on. Stupid? Yeah, but it's either that or warnings on all versions but 1. Blame Joe.
*/
@Override public SourceVersion getSupportedSourceVersion() {
return SourceVersion.values()[SourceVersion.values().length - 1];
return SourceVersion.latest();
}
}
2 changes: 1 addition & 1 deletion src/core/lombok/javac/HandlerLibrary.java
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public class HandlerLibrary {

/**
* Creates a new HandlerLibrary that will report any problems or errors to the provided messager.
* You probably want to use {@link #load(Messager)} instead.
* You probably want to use {@link #load(Messager, Trees)} instead.
*/
public HandlerLibrary(Messager messager) {
ConfigurationKeysLoader.LoaderLoader.loadAllConfigurationKeys();
Expand Down
2 changes: 1 addition & 1 deletion src/core/lombok/javac/apt/LombokProcessor.java
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@ private Object tryGetFilerField(Class<?> delegateClass, Object instance) {
}

/**
* InteliJ >= 2020.3
* IntelliJ IDEA >= 2020.3
*/
private Object tryGetProxyDelegateToField(Class<?> delegateClass, Object instance) {
try {
Expand Down
2 changes: 1 addition & 1 deletion src/core/lombok/javac/apt/Processor.java
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ private static String escape(char ch) {
* We just return the latest version of whatever JDK we run on. Stupid? Yeah, but it's either that or warnings on all versions but 1.
*/
@Override public SourceVersion getSupportedSourceVersion() {
return SourceVersion.values()[SourceVersion.values().length - 1];
return SourceVersion.latest();
}

@Override public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) {
Expand Down

0 comments on commit 648a56c

Please sign in to comment.