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/03/28 02:39:15 UTC

[groovy] branch danielsun/address-github-actions-errors updated (cc557a9 -> 061c12e)

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

sunlan pushed a change to branch danielsun/address-github-actions-errors
in repository https://gitbox.apache.org/repos/asf/groovy.git.


 discard cc557a9  Try to fix the failing build
     new 061c12e  Try to fix the failing build - 2

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (cc557a9)
            \
             N -- N -- N   refs/heads/danielsun/address-github-actions-errors (061c12e)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../org/codehaus/groovy/reflection/ClassInfo.java    | 20 +++++++++++++++-----
 1 file changed, 15 insertions(+), 5 deletions(-)


[groovy] 01/01: Try to fix the failing build - 2

Posted by su...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sunlan pushed a commit to branch danielsun/address-github-actions-errors
in repository https://gitbox.apache.org/repos/asf/groovy.git

commit 061c12e821dd58310d2ae4977dd10e563fd35b07
Author: Daniel Sun <su...@apache.org>
AuthorDate: Sat Mar 28 10:38:15 2020 +0800

    Try to fix the failing build - 2
---
 .../org/codehaus/groovy/reflection/ClassInfo.java     | 19 +++++++++++++------
 1 file changed, 13 insertions(+), 6 deletions(-)

diff --git a/src/main/java/org/codehaus/groovy/reflection/ClassInfo.java b/src/main/java/org/codehaus/groovy/reflection/ClassInfo.java
index 77b2c5f..838d6a0 100644
--- a/src/main/java/org/codehaus/groovy/reflection/ClassInfo.java
+++ b/src/main/java/org/codehaus/groovy/reflection/ClassInfo.java
@@ -321,14 +321,21 @@ public class ClassInfo implements Finalizable {
      * @return a {@code MetaClass} instance
      */
     public final MetaClass getMetaClass() {
-        MetaClass answer = getMetaClassForClass();
-        if (answer != null) return answer;
-
-        lock();
+        MetaClass answer = null;
         try {
-            return getMetaClassUnderLock();
+            answer = getMetaClassForClass();
+            if (answer != null) return answer;
+
+            lock();
+            try {
+                return getMetaClassUnderLock();
+            } finally {
+                unlock();
+            }
         } finally {
-            unlock();
+            if (null != answer) {
+                answer.initialize();
+            }
         }
     }