You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by su...@apache.org on 2020/02/14 18:35:33 UTC

[groovy] 01/01: Fix the failing build

This is an automated email from the ASF dual-hosted git repository.

sunlan pushed a commit to branch danielsun/classnode-position-issue
in repository https://gitbox.apache.org/repos/asf/groovy.git

commit d943d0f4f639665c20c2539fb1b43ca54171dff6
Author: Daniel Sun <su...@apache.org>
AuthorDate: Sat Feb 15 02:35:00 2020 +0800

    Fix the failing build
---
 src/main/java/org/codehaus/groovy/ast/ClassHelper.java | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/main/java/org/codehaus/groovy/ast/ClassHelper.java b/src/main/java/org/codehaus/groovy/ast/ClassHelper.java
index 17bcc8d..97287f3 100644
--- a/src/main/java/org/codehaus/groovy/ast/ClassHelper.java
+++ b/src/main/java/org/codehaus/groovy/ast/ClassHelper.java
@@ -98,9 +98,10 @@ public class ClassHelper {
             "", "boolean", "char", "byte", "short", "int", "long", "double", "float", "void"
     };
 
+    public static final String OBJECT = "java.lang.Object";
     public static final ClassNode
             DYNAMIC_TYPE = makeCached(Object.class),
-            OBJECT_TYPE = DYNAMIC_TYPE,
+            OBJECT_TYPE = makeWithoutCaching(OBJECT),
             CLOSURE_TYPE = makeCached(Closure.class),
             GSTRING_TYPE = makeCached(GString.class),
             RANGE_TYPE = makeCached(Range.class),
@@ -173,8 +174,6 @@ public class ClassHelper {
 
     protected static final ClassNode[] EMPTY_TYPE_ARRAY = {};
 
-    public static final String OBJECT = "java.lang.Object";
-
     public static ClassNode makeCached(Class c) {
         final SoftReference<ClassNode> classNodeSoftReference = ClassHelperCache.classCache.get(c);
         ClassNode classNode;