https://kotlinlang.org logo
#compose
Title
# compose
r

raulraja

06/09/2019, 8:42 PM
Hi!, Jetpack Compose makes use of extensions such as
org.jetbrains.kotlin.extensions.TypeResolutionInterceptorExtension
in its component registration. I looked in Github and there are no such extensions in the Kotlin Compiler master branch. Where are those extensions coming from? Is there a list of available extensions available? Thanks.
👍 3
Here is some of the extensions that I can resolve in the compiler sources and those that Jetpack Compose is referencing and not sure where they come from:
Copy code
// found in the classpath
import org.jetbrains.kotlin.codegen.extensions.ClassBuilderInterceptorExtension
import org.jetbrains.kotlin.resolve.jvm.extensions.AnalysisHandlerExtension
import org.jetbrains.kotlin.extensions.StorageComponentContainerContributor

// not in the Kotlin compiler sources
import org.jetbrains.kotlin.backend.jvm.extensions.IrLoweringExtension
import org.jetbrains.kotlin.extensions.CallResolutionInterceptorExtension
import org.jetbrains.kotlin.extensions.KtxControlFlowExtension
import org.jetbrains.kotlin.extensions.KtxTypeResolutionExtension
import org.jetbrains.kotlin.extensions.TypeResolutionInterceptorExtension
import org.jetbrains.kotlin.parsing.KtxParsingExtension
import org.jetbrains.kotlin.psi2ir.extensions.SyntheticIrExtension
r

romainguy

06/09/2019, 9:42 PM
We've had to make a few mods to the compiler and working with JB on upstreaming them
r

raulraja

06/09/2019, 10:53 PM
Are those mods available in sources elsewhere or can that version of the compiler be depended on to have a preview of those features?. I’m trying to come up with some internal docs as to what phases there are for extensions given there is no docs for compiler plugins but is the only way to go for multiplatform meta at the moment.
r

romainguy

06/10/2019, 4:42 AM
The sources are not available and since we’re the only ones with that compiler at the moment I wouldn’t depend on it. The compiler plugin APIs aren’t stable anyway I believe
2 Views