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

emilles pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/groovy.git


The following commit(s) were added to refs/heads/master by this push:
     new a52a3888c9 vmplugin: missing class erorr
a52a3888c9 is described below

commit a52a3888c9c82c04369b0a61f02216d7f7afadad
Author: Eric Milles <eric.mil...@thomsonreuters.com>
AuthorDate: Wed Oct 25 15:46:39 2023 -0500

    vmplugin: missing class erorr
---
 src/main/java/org/codehaus/groovy/vmplugin/v8/Java8.java | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/main/java/org/codehaus/groovy/vmplugin/v8/Java8.java 
b/src/main/java/org/codehaus/groovy/vmplugin/v8/Java8.java
index cec940a600..8f01493820 100644
--- a/src/main/java/org/codehaus/groovy/vmplugin/v8/Java8.java
+++ b/src/main/java/org/codehaus/groovy/vmplugin/v8/Java8.java
@@ -57,6 +57,7 @@ import java.lang.reflect.Array;
 import java.lang.reflect.Constructor;
 import java.lang.reflect.Field;
 import java.lang.reflect.GenericArrayType;
+import java.lang.reflect.GenericSignatureFormatError;
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.MalformedParameterizedTypeException;
 import java.lang.reflect.Member;
@@ -423,9 +424,11 @@ public class Java8 implements VMPlugin {
                 setAnnotationMetaData(clazz.getPackage().getAnnotations(), 
packageNode);
             }
         } catch (NoClassDefFoundError e) {
-            throw new NoClassDefFoundError("Unable to load class " + 
classNode.toString(false) + " due to missing dependency " + e.getMessage());
-        } catch (MalformedParameterizedTypeException e) {
-            throw new RuntimeException("Unable to configure class node for 
class " + classNode.toString(false) + " due to malformed parameterized types", 
e);
+            throw new NoClassDefFoundError("Unable to configure " + 
classNode.getName() + " due to missing dependency " + e.getMessage());
+        } catch (TypeNotPresentException e) {
+            throw new NoClassDefFoundError("Unable to configure " + 
classNode.getName() + " due to missing dependency " + e.typeName());
+        } catch (GenericSignatureFormatError | 
MalformedParameterizedTypeException e) {
+            throw new RuntimeException(    "Unable to configure " + 
classNode.getName() + " due to malformed type info" , e);
         }
     }
 

Reply via email to