@@ -1334,22 +1334,22 @@ MethodHandle buildAliasHandle(ThreadContext context, CacheEntry entry, IRubyObje
13341334 if (method instanceof PartialDelegatingMethod delegate ) {
13351335 DynamicMethod innerMethod = delegate .getRealMethod ();
13361336 mh = getHandle (context , self , new CacheEntry (innerMethod , entry .sourceModule , entry .token ));
1337- } else if (method instanceof AliasMethod alias ) {
1338- DynamicMethod innerMethod = alias .getRealMethod ();
1339- String name = alias .getName ();
1340-
1341- // Use a second site to mimic invocation from AliasMethod
1342- MethodType type = type ();
1343- if (!functional ) type = type .dropParameterTypes (1 , 2 );
1344- InvokeSite innerSite = (InvokeSite ) SelfInvokeSite .bootstrap (LOOKUP , "callFunctional:" + name , type , literalClosure ? 1 : 0 , flags , file , line );
1345- mh = innerSite .getHandle (context , self , new CacheEntry (innerMethod , entry .sourceModule , entry .token ));
1346- if (!functional ) mh = MethodHandles .dropArguments (mh , 1 , IRubyObject .class );
1347-
1348- alias .setHandle (mh );
1349-
1350- if (Options .INVOKEDYNAMIC_LOG_BINDING .load ()) {
1351- LOG .info (name () + "\t bound directly through alias to " + Bootstrap .logMethod (method ));
1352- }
1337+ // } else if (method instanceof AliasMethod alias) {
1338+ // DynamicMethod innerMethod = alias.getRealMethod();
1339+ // String name = alias.getName();
1340+ //
1341+ // // Use a second site to mimic invocation from AliasMethod
1342+ // MethodType type = type();
1343+ // if (!functional) type = type.dropParameterTypes(1, 2);
1344+ // InvokeSite innerSite = (InvokeSite) SelfInvokeSite.bootstrap(LOOKUP, "callFunctional:" + name, type, literalClosure ? 1 : 0, flags, file, line);
1345+ // mh = innerSite.getHandle(context, self, new CacheEntry(innerMethod, entry.sourceModule, entry.token));
1346+ // if (!functional) mh = MethodHandles.dropArguments(mh, 1, IRubyObject.class);
1347+ //
1348+ // alias.setHandle(mh);
1349+ //
1350+ // if (Options.INVOKEDYNAMIC_LOG_BINDING.load()) {
1351+ // LOG.info(name() + "\tbound directly through alias to " + Bootstrap.logMethod(method));
1352+ // }
13531353 }
13541354
13551355 return mh ;
0 commit comments