paulk-asert commented on code in PR #2673:
URL: https://github.com/apache/groovy/pull/2673#discussion_r3549143055
##########
src/main/java/org/codehaus/groovy/vmplugin/v8/Selector.java:
##########
@@ -1226,6 +1251,35 @@ void buildInvokeHandle() {
addExceptionHandler();
}
}
+
+ @Override
+ MetaMethod selectForColdReflection() {
+ // defensive: the cold tier is only for plain method calls; the
+ // fallback gates on CallType.METHOD, so subclasses (CastSelector,
+ // InterfaceSelector) are never asked, but make it explicit here
+ if (callType != CallType.METHOD) return null;
+ // these all need the full handle path: spread and safe-null have
+ // their own adaptation/constant handles; a null receiver means
+ // NullObject MOP dispatch; a Class receiver is a static-method
Review Comment:
(NullObject): You're right — nothing fundamental prevents serving
NullObject's methods reflectively; the exclusion was spike conservatism. Marked
as TODO as suggested.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]