From 1b534d17d39f687d42ebab733327a59c3466a949 Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Sat, 3 Oct 2020 23:51:33 +0200 Subject: Untangling patches to classes that only exist in eclipse, not ecj Specifically, Rawi01's patches to make javadoc behaviour in eclipse better, which cannot be applied to ecj as you get load errors (javadoc not a thing there). As part of this commit, tests can be limited to ecj or eclipse, and I made cut-down versions of a few tests (to run on ecj, as the main one cannot be, due to javadoc issues). The tests now marked as eclipse only don't fail on ecj, but they don't generate the same result. Alternatively, we could go with a separated out after-ecj and after-eclipse dir instead, but that's perhaps going overboard. --- src/eclipseAgent/lombok/eclipse/agent/PatchDelegate.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/eclipseAgent/lombok/eclipse/agent/PatchDelegate.java') diff --git a/src/eclipseAgent/lombok/eclipse/agent/PatchDelegate.java b/src/eclipseAgent/lombok/eclipse/agent/PatchDelegate.java index e92ed674..b90d5762 100644 --- a/src/eclipseAgent/lombok/eclipse/agent/PatchDelegate.java +++ b/src/eclipseAgent/lombok/eclipse/agent/PatchDelegate.java @@ -22,7 +22,7 @@ package lombok.eclipse.agent; import static lombok.eclipse.Eclipse.*; -import static lombok.eclipse.EclipseAugments.*; +import static lombok.eclipse.EcjAugments.*; import static lombok.eclipse.handlers.EclipseHandlerUtil.*; import java.lang.reflect.Method; @@ -724,7 +724,7 @@ public class PatchDelegate { private static void cleanupDelegateMethods(CompilationUnitDeclaration cud) { CompilationUnit compilationUnit = getCompilationUnit(cud); if (compilationUnit != null) { - CompilationUnit_delegateMethods.clear(compilationUnit); + EclipseAugments.CompilationUnit_delegateMethods.clear(compilationUnit); } } @@ -819,7 +819,7 @@ public class PatchDelegate { if (sourceType != null) { CompilationUnit compilationUnit = getCompilationUnit(sourceType.getCompilationUnit()); if (compilationUnit != null) { - ConcurrentMap> map = CompilationUnit_delegateMethods.setIfAbsent(compilationUnit, new ConcurrentHashMap>()); + ConcurrentMap> map = EclipseAugments.CompilationUnit_delegateMethods.setIfAbsent(compilationUnit, new ConcurrentHashMap>()); List newList = new ArrayList(); List oldList = map.putIfAbsent(sourceType.getTypeQualifiedName(), newList); return oldList != null ? oldList : newList; -- cgit