https://kotlinlang.org logo
Title
y

yigit

02/27/2021, 8:33 PM
Would be great to have all of it out of the box
e

elihart

02/27/2021, 9:59 PM
y

yigit

02/27/2021, 10:38 PM
I think this would be good to have from the javapoet side as @Zac Sweers mentioned
z

Zac Sweers

02/27/2021, 10:42 PM
maybe we need something like rxjava's interop libraries ha
kotlinpoet - javapoet interop
kotlinpoet - ksp interop
kotlinpoet - kotlinx-metadata
etc etc
y

yigit

02/27/2021, 10:43 PM
😬
z

Zac Sweers

02/27/2021, 10:44 PM
I mean, all of these effectively exist in one form or another in multiple places
one consistent bit would be that kotlinpoet would be the sort of common point
so if you want to go from ksp to javapoet, you go to kotlinpoet first then interop to javapoet
y

yigit

02/27/2021, 10:45 PM
Yes we already know 3-4 impls :). Doesn't get better demand proof then that
z

Zac Sweers

02/27/2021, 10:45 PM
same with kotlinx-metadata
yup
let me talk to egor, I think this is a pretty compelling case to make a set of interop artifacts
🙏 2
@egorand ^^
e

egorand

02/27/2021, 11:42 PM
So the idea being for any Kotlin-specific tools (KSP being an instance) that want to generate Java to go through KotlinPoet’s bridge to JavaPoet? This does make sense to me
🎉 1
z

Zac Sweers

02/27/2021, 11:42 PM
yeah that's what I'm thinking. Then we just make a set of interop artifacts alongside the existing metadata artifacts
started a first pass at a new interop structure: https://github.com/square/kotlinpoet/pull/1041
👍 2