[code-reflection] RFR: Code model from method reference
Maurizio Cimadamore
mcimadamore at openjdk.org
Wed Mar 6 09:45:08 UTC 2024
On Tue, 5 Mar 2024 21:34:39 GMT, Paul Sandoz <psandoz at openjdk.org> wrote:
> Obtain a code model from method reference. The implementation is simple and resolves the method reference to an instance of `Method`, and returns the result of `Method::getCodeModel`.
Marked as reviewed by mcimadamore (Reviewer).
src/java.base/share/classes/java/lang/reflect/code/type/MethodRef.java line 68:
> 66: MethodHandle resolveToHandle(MethodHandles.Lookup l) throws ReflectiveOperationException;
> 67:
> 68: Optional<CoreOps.FuncOp> codeModel(MethodHandles.Lookup l) throws ReflectiveOperationException;
If the result is optional, do we also need the `throws` ?
-------------
PR Review: https://git.openjdk.org/babylon/pull/34#pullrequestreview-1919245283
PR Review Comment: https://git.openjdk.org/babylon/pull/34#discussion_r1514147953
More information about the babylon-dev
mailing list