diff options
author | Rawi01 <Rawi01@users.noreply.github.com> | 2021-02-17 09:41:08 +0100 |
---|---|---|
committer | Rawi01 <Rawi01@users.noreply.github.com> | 2021-02-17 09:41:08 +0100 |
commit | 0106746e60263d8cc3fbd189cca7b2e09c3d5c06 (patch) | |
tree | 11492f7c5e3488d203e82a91a3ceb398fca5aa1a /src | |
parent | ed4ced1a3bc694f9a9903b5a15b2641236ff2f92 (diff) | |
download | lombok-0106746e60263d8cc3fbd189cca7b2e09c3d5c06.tar.gz lombok-0106746e60263d8cc3fbd189cca7b2e09c3d5c06.tar.bz2 lombok-0106746e60263d8cc3fbd189cca7b2e09c3d5c06.zip |
[fixes #2752] Save problem handler state for postponed error handling
Diffstat (limited to 'src')
-rw-r--r-- | src/eclipseAgent/lombok/eclipse/agent/PatchExtensionMethod.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/eclipseAgent/lombok/eclipse/agent/PatchExtensionMethod.java b/src/eclipseAgent/lombok/eclipse/agent/PatchExtensionMethod.java index 5f229955..fd8a13b7 100644 --- a/src/eclipseAgent/lombok/eclipse/agent/PatchExtensionMethod.java +++ b/src/eclipseAgent/lombok/eclipse/agent/PatchExtensionMethod.java @@ -55,6 +55,7 @@ import org.eclipse.jdt.internal.compiler.ast.SingleNameReference; import org.eclipse.jdt.internal.compiler.ast.SuperReference; import org.eclipse.jdt.internal.compiler.ast.ThisReference; import org.eclipse.jdt.internal.compiler.ast.TypeDeclaration; +import org.eclipse.jdt.internal.compiler.impl.ReferenceContext; import org.eclipse.jdt.internal.compiler.lookup.Binding; import org.eclipse.jdt.internal.compiler.lookup.BlockScope; import org.eclipse.jdt.internal.compiler.lookup.MethodBinding; @@ -143,14 +144,17 @@ public class PatchExtensionMethod { private final ProblemReporter problemReporter; private ASTNode location; private MethodBinding method; + private ReferenceContext referenceContext; PostponedNonStaticAccessToStaticMethodError(ProblemReporter problemReporter, ASTNode location, MethodBinding method) { this.problemReporter = problemReporter; this.location = location; this.method = method; + this.referenceContext = problemReporter.referenceContext; } public void fire() { + problemReporter.referenceContext = this.referenceContext; problemReporter.nonStaticAccessToStaticMethod(location, method); } } |