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

sunlan 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 b05a16a  Trivial refactoring: simplify code
b05a16a is described below

commit b05a16af6ae75ff37d1c9056e9856c7adede15ce
Author: Daniel Sun <[email protected]>
AuthorDate: Sun Oct 3 22:01:11 2021 +0800

    Trivial refactoring: simplify code
---
 src/main/java/org/codehaus/groovy/reflection/ReflectionUtils.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/main/java/org/codehaus/groovy/reflection/ReflectionUtils.java 
b/src/main/java/org/codehaus/groovy/reflection/ReflectionUtils.java
index e85883b..dccab1f 100644
--- a/src/main/java/org/codehaus/groovy/reflection/ReflectionUtils.java
+++ b/src/main/java/org/codehaus/groovy/reflection/ReflectionUtils.java
@@ -247,7 +247,7 @@ public class ReflectionUtils {
 
         boolean sealed = false;
         try {
-            sealed = (boolean) 
IS_SEALED_METHODHANDLE.bindTo(clazz).invokeExact();
+            sealed = (boolean) IS_SEALED_METHODHANDLE.invokeExact(clazz);
         } catch (Throwable ignored) {
         }
         return sealed;
@@ -259,7 +259,7 @@ public class ReflectionUtils {
 
         Class<?>[] result = EMPTY_CLASS_ARRAY;
         try {
-            result = (Class<?>[]) 
GET_PERMITTED_SUBCLASSES_METHODHANDLE.bindTo(clazz).invokeExact();
+            result = (Class<?>[]) 
GET_PERMITTED_SUBCLASSES_METHODHANDLE.invokeExact(clazz);
         } catch (Throwable ignored) {
         }
         return result;

Reply via email to