micronaut-projects / micronaut-core

Micronaut Application Framework
http://micronaut.io
Apache License 2.0
6.06k stars 1.06k forks source link

kspKotlin fails with java enum in kotlin project #9642

Closed hauner closed 8 months ago

hauner commented 1 year ago

Expected Behavior

compilation of the kotlin project with a java enum should succeed

Actual Behaviour

kspKotlin fails with

[ksp] java.lang.IllegalStateException: unexpected class: class com.google.devtools.ksp.symbol.impl.java.KSClassDeclarationJavaEnumEntryImpl
    at com.google.devtools.ksp.processing.impl.ResolverImpl.resolveClassDeclaration(ResolverImpl.kt:568)
    at com.google.devtools.ksp.processing.impl.ResolverImpl.mapToJvmSignatureInternal$compiler_plugin(ResolverImpl.kt:356)
    at com.google.devtools.ksp.processing.impl.ResolverImpl.mapToJvmSignature(ResolverImpl.kt:353)
    at io.micronaut.kotlin.processing.ExtensionsKt.getBinaryName(extensions.kt:47)
...

Steps To Reproduce

  1. build
  2. kspKotlin fails

Environment Information

Example Application

https://github.com/hauner/demo-enum

Version

4.0.1

tamershahin commented 1 year ago

any news on this one?

dstepanov commented 1 year ago

It's broken in KSP https://github.com/google/ksp/issues/1482

altro3 commented 8 months ago

@dstepanov it works fine now. Can be closed