From eeb8edd55691b99f7cbd1b2a6c05cad208e6e99c Mon Sep 17 00:00:00 2001 From: cartland Date: Thu, 15 Aug 2024 13:37:01 -0700 Subject: [PATCH] Add @Suppress("NO_ACTUAL_FOR_EXPECT") for Room impementation * Room will generate `actual` classes for `expect` RoomDatabaseConstructor --- .../kotlin/com/example/fruitties/database/AppDatabase.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Fruitties/shared/src/commonMain/kotlin/com/example/fruitties/database/AppDatabase.kt b/Fruitties/shared/src/commonMain/kotlin/com/example/fruitties/database/AppDatabase.kt index 8c6b2cf..ea79504 100644 --- a/Fruitties/shared/src/commonMain/kotlin/com/example/fruitties/database/AppDatabase.kt +++ b/Fruitties/shared/src/commonMain/kotlin/com/example/fruitties/database/AppDatabase.kt @@ -27,6 +27,8 @@ abstract class AppDatabase : RoomDatabase() { abstract fun fruittieDao(): FruittieDao } +// The Room compiler will generate the `actual` implementations. +@Suppress("NO_ACTUAL_FOR_EXPECT") expect object AppDatabaseConstructor : RoomDatabaseConstructor internal const val dbFileName = "fruits.db"