Hacker News new | comments | show | ask | jobs | submit login

How misleading? Pretty much everything available in Java is available directly in the bytecode. Java compiles to bytecode, any JVM based language can use utilize the same bytecode(s).

There is even more: invokeDynamic, Java (the language) doesn't use it in its compiled bytecode and the JVM instruction is targeted at JVM based languages. (InvokeDynamic is still available from Java via java.lang.invoke)

Java emits invokeDynamic instructions as part of lambda execution.

technically, the lambda creation, not it's execution. It's also used for string concatenation in Java 9.

while invokedynamic was introduced to enhance the support of dynamic languages on the JVM, invokedynamic is now used as a kind of macro instruction to avoid to add new instructions in the bytecode set when the instruction can be decomposed in a set of already existing instructions.

In Java 9 string concatenation it isn't for macro use but to allow the run time to make the final determination as to how it is going to actually do the joining since there are now multiple strategies available to process the strings and possibly user overrideable behavior to incorporate.

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact