tschuchortdev / kotlin-compile-testing

A library for testing Kotlin and Java annotation processors, compiler plugins and code generation
Mozilla Public License 2.0
642 stars 61 forks source link

resolver.getSymbolsWithAnnotation return null #395

Open Mao0509 opened 6 months ago

Mao0509 commented 6 months ago

image this return false lead to getSymbolsWithAnnotation return null annotationType.resolveToUnderlying() return ERROR TYPE

What is the reason for this? The AS Rebuild Project does not make this error Android Studio Hedgehog | 2023.1.1 Runtime version: 17.0.7+0-b2043.56-10550314 amd64 ksp: 1.9.22-1.0.16 com.github.tschuchortdev:kotlin-compile-testing-ksp:1.5.0

tschuchortdev commented 1 month ago

I don't see how this is related to the KCT library. Can you provide more information? Perhaps the annotated class is not on the classpath.

Aidanvii7 commented 2 weeks ago

@Mao0509 I had the same problem, in the end inheritClassPath = true fixed it.