KotlinMeta

Hello everybody! I've just wathced Ilya's MBLTDev and he mentioned Kotlin's reflection. What would it be? Is it compile time or runtime reflection? Do you plan to make some kind of macroses? Or it would be runtime wrapper for Java's reflection? Would it be possible to generate code at compiletime? Is it some provided apis to ast?

There is some development of something “dynamic”. That is it or just javascript stuff?

On reflection: It is traditional run-time reflection, no macros, AST APIs are planned for future versions

On dynamic: we are working on dynamic types for JavaScript interop, no support on the JVM is planned for the nearest future.

Reflection mentioned is Kotlin-specific runtime type information. It provides information about properties, objects, nullity, default parameters, and other things that do not exist in Java. We don't plan to do something like "macroses", at least not in any forseeable future. We do plan to support compile-time code generation though, via compiler plugins and/or something like Java's Annotation Processing tools. Dynamic is currently just for JavaScript for interoperability with existing (untyped) libraries, but in the future we consider support for dynamic in JVM backend as well.

Good to know, thank you! Do you have any roadmap to expect some features in particular milestones? Waiting for codegeneration tools :)

What kind of code generation tools do you mean?

Sure, I mean, a hook to annotation processor would be enough to use existing code writers

Oh, I see. Yeah, as Ilya said above, it's on the horizon :)