diff options
author | Rawi01 <Rawi01@users.noreply.github.com> | 2020-07-12 01:01:18 +0200 |
---|---|---|
committer | Roel Spilker <r.spilker@gmail.com> | 2020-07-12 01:22:38 +0200 |
commit | ce92389da76b17b2c8d9f8757d67b4ea3edc8cb5 (patch) | |
tree | 6af318429ac0b2c06692dd2511103460381395e7 /src/eclipseAgent/lombok | |
parent | 4fdcdd126a4b5ce365b97eb498536d04caee3b53 (diff) | |
download | lombok-ce92389da76b17b2c8d9f8757d67b4ea3edc8cb5.tar.gz lombok-ce92389da76b17b2c8d9f8757d67b4ea3edc8cb5.tar.bz2 lombok-ce92389da76b17b2c8d9f8757d67b4ea3edc8cb5.zip |
[fixes #977] Set generated flag for annotation names
Diffstat (limited to 'src/eclipseAgent/lombok')
-rw-r--r-- | src/eclipseAgent/lombok/eclipse/agent/EclipsePatcher.java | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/eclipseAgent/lombok/eclipse/agent/EclipsePatcher.java b/src/eclipseAgent/lombok/eclipse/agent/EclipsePatcher.java index 95d42c2c..c560f002 100644 --- a/src/eclipseAgent/lombok/eclipse/agent/EclipsePatcher.java +++ b/src/eclipseAgent/lombok/eclipse/agent/EclipsePatcher.java @@ -575,6 +575,22 @@ public class EclipsePatcher implements AgentLauncher.AgentLaunchable { .wrapMethod(new Hook("lombok.launch.PatchFixesHider$PatchFixes", "setIsGeneratedFlagForName", "void", "org.eclipse.jdt.core.dom.Name", "java.lang.Object")) .transplant().build()); + + sm.addScript(ScriptBuilder.wrapMethodCall() + .target(new MethodTarget("org.eclipse.jdt.core.dom.ASTConverter", "setTypeNameForAnnotation", "void", "org.eclipse.jdt.internal.compiler.ast.Annotation", "org.eclipse.jdt.core.dom.Annotation")) + .methodToWrap(new Hook("org.eclipse.jdt.core.dom.SimpleName", "<init>", "void", "org.eclipse.jdt.core.dom.AST")) + .requestExtra(StackRequest.PARAM1) + .wrapMethod(new Hook("lombok.launch.PatchFixesHider$PatchFixes", "setIsGeneratedFlagForName", "void", + "org.eclipse.jdt.core.dom.Name", "java.lang.Object")) + .transplant().build()); + + sm.addScript(ScriptBuilder.wrapMethodCall() + .target(new MethodTarget("org.eclipse.jdt.core.dom.ASTConverter", "setTypeNameForAnnotation", "void", "org.eclipse.jdt.internal.compiler.ast.Annotation", "org.eclipse.jdt.core.dom.Annotation")) + .methodToWrap(new Hook("org.eclipse.jdt.core.dom.QualifiedName", "<init>", "void", "org.eclipse.jdt.core.dom.AST")) + .requestExtra(StackRequest.PARAM1) + .wrapMethod(new Hook("lombok.launch.PatchFixesHider$PatchFixes", "setIsGeneratedFlagForName", "void", + "org.eclipse.jdt.core.dom.Name", "java.lang.Object")) + .transplant().build()); } private static void patchAvoidReparsingGeneratedCode(ScriptManager sm) { |