summaryrefslogtreecommitdiff
path: root/test/2280-const-method-handle-validation
AgeCommit message (Collapse)Author
2024-09-24Add more validation for const-method-handle. Almaz Mingaleev
Making it closer to JVMS 4.4.8 and 5.4.3.5. The RI rejects certain constructions at the class verification stage, hence there are separate classes for MethodHandle-s targeting <init> and <clinit> methods. In these cases The RI throws ClassFormatError during class load, but currently we do validations only when actual MethodHandle object is constructed, that's is the reason why test code has ICCE | CFE in catch blocks. That will be addressed in the upcoming CLs. This should not cause any compat issues as even if some of these MethodHandle were constructed successfully, their invocation leads to runtime crashes. Bug: 297147201 Test: ./art/test/testrunner/testrunner.py --host --64 --jvm -b Change-Id: I551b04e3c00ffc8bcdeac4760d9ac4b3bb7b2aff