diff --git a/kotlin-native/backend.native/tests/objcexport/expectedLazy.h b/kotlin-native/backend.native/tests/objcexport/expectedLazy.h index 6e0e4f0784c..adbd1bc7a9d 100644 --- a/kotlin-native/backend.native/tests/objcexport/expectedLazy.h +++ b/kotlin-native/backend.native/tests/objcexport/expectedLazy.h @@ -842,6 +842,7 @@ __attribute__((swift_name("KT43780Enum"))) + (instancetype)alloc __attribute__((unavailable)); + (instancetype)allocWithZone:(struct _NSZone *)zone __attribute__((unavailable)); - (instancetype)initWithName:(NSString *)name ordinal:(int32_t)ordinal __attribute__((swift_name("init(name:ordinal:)"))) __attribute__((objc_designated_initializer)) __attribute__((unavailable)); +@property (class, readonly) KtKT43780Enum *otherEntry __attribute__((swift_name("otherEntry"))); @property (class, readonly) KtKT43780Enum *companion __attribute__((swift_name("companion"))); + (KtKotlinArray *)values __attribute__((swift_name("values()"))); @end; diff --git a/kotlin-native/backend.native/tests/objcexport/expectedLazyNoGenerics.h b/kotlin-native/backend.native/tests/objcexport/expectedLazyNoGenerics.h index 4a62093e58a..98c3e4b5459 100644 --- a/kotlin-native/backend.native/tests/objcexport/expectedLazyNoGenerics.h +++ b/kotlin-native/backend.native/tests/objcexport/expectedLazyNoGenerics.h @@ -784,6 +784,7 @@ __attribute__((swift_name("KT43780Enum"))) + (instancetype)alloc __attribute__((unavailable)); + (instancetype)allocWithZone:(struct _NSZone *)zone __attribute__((unavailable)); - (instancetype)initWithName:(NSString *)name ordinal:(int32_t)ordinal __attribute__((swift_name("init(name:ordinal:)"))) __attribute__((objc_designated_initializer)) __attribute__((unavailable)); +@property (class, readonly) KtKT43780Enum *otherEntry __attribute__((swift_name("otherEntry"))); @property (class, readonly) KtKT43780Enum *companion __attribute__((swift_name("companion"))); + (KtKotlinArray *)values __attribute__((swift_name("values()"))); @end; diff --git a/kotlin-native/backend.native/tests/objcexport/kt43780.kt b/kotlin-native/backend.native/tests/objcexport/kt43780.kt index d82bb8b65e9..c255ba25d33 100644 --- a/kotlin-native/backend.native/tests/objcexport/kt43780.kt +++ b/kotlin-native/backend.native/tests/objcexport/kt43780.kt @@ -28,6 +28,7 @@ class Companion { } enum class KT43780Enum { + OTHER_ENTRY, COMPANION; companion object { diff --git a/kotlin-native/backend.native/tests/objcexport/kt43780.swift b/kotlin-native/backend.native/tests/objcexport/kt43780.swift index a1a6bf565a7..d509d42e95e 100644 --- a/kotlin-native/backend.native/tests/objcexport/kt43780.swift +++ b/kotlin-native/backend.native/tests/objcexport/kt43780.swift @@ -34,6 +34,7 @@ private func testNameClash() throws { try assertTrue(object5 === KT43780Enum.Companion()) let enumEntry : KT43780Enum = KT43780Enum.companion try assertEquals(actual: enumEntry.name, expected: "COMPANION") + try assertEquals(actual: KT43780Enum.otherEntry.name, expected: "OTHER_ENTRY") }