Hello! I want to integrate a target into an iOS pr...
# compose-desktop
в
Hello! I want to integrate a target into an iOS project using Compose Multiplatform. I am using
Kotlin version 1.7.20
(Compose Multiplatform does not allow above),
agp version 7.4.0-beta02
. In Gradle, I connected iOS target, locked all platform features on the iOS side. To build the ios module I use the command
./gradlew clean ios:iosDeployIPhone13Debug
As a result, I get an error (shortened version), where almost all project files are listed in Source files:
> Task :common:compileKotlinUikitX64 FAILED
e: Compilation failed: null cannot be cast to non-null type org.jetbrains.kotlin.ir.declarations.IrFunction
* Source files: AppDatabase.kt, AppDatabaseImpl.kt, AccountsEntity.kt, AccountsEntityQueries.kt, CategoriesEntity.kt, CategoriesEntityQueries.kt, CurrencyRatesEntity.kt, CurrencyRatesEntityQueries.kt, G....
I found only this issue in Google, which is very similar to my mistake, but in my project I checked that there are no expect functions with default values in any file. At the same time, the files that are listed in the Source files do not contain within themselves the code associated with Compose or expect / actual. How to fix this error? In which direction should I look?
l
A note on the Kotlin version: 1.3.0-rc02 allows Kotlin 1.8.0
Try marking all Composable methods as internal. This fixed a similar issue for me.
в
A note on the Kotlin version: 1.3.0-rc02 allows Kotlin 1.8.0
And what kotlin
kotlinCompilerExtensionVersion
version should I use for Kotlin 1.8.0?
Try marking all Composable methods as internal. This fixed a similar issue for me.
I try it, thank you
l
It should work by default if you don’t specify a compiler version.
If you do want to specify a version of the compose compiler, use the new forKotlin(version) method.
в
Could you send me link on
new forKotlin(version) method
please? I can't find it
в
internal
a little bit helped me, but this error occurred again
n
but this error occurred again
Please submit an issue with reproducible sample.