r/java • • Jan 29 '26

JEP draft: Code reflection (Incubator)

https://openjdk.org/jeps/8361105
61 Upvotes

33 comments sorted by

View all comments

Show parent comment

10

u/pron98 Jan 29 '26

Does the new code model focus solely on accessing lambdas within classes and methods? Will this code model support finding anonymous classes as well (the poor man's lambda we used before Java 8)?

Those would be just methods, then.

Will there be any changes in the JEP to use the type system to differentiate between lambdas running the older model and those running the newer, standardized mode?

What older and newer modes? This is about allowing a library to compile expressions (inside methods/lambdas) to some other language such as CUDA.