This commit is contained in:
SvyatoslavScherbina
2019-04-29 16:55:34 +03:00
committed by GitHub
parent 8a4f06cdaf
commit dd1d229297
2 changed files with 2 additions and 1 deletions
@@ -63,7 +63,7 @@ internal fun ObjCExportedInterface.createCodeSpec(symbolTable: SymbolTable): Obj
}
}
if (descriptor.kind == ClassKind.ENUM_ENTRY) {
if (descriptor.kind == ClassKind.ENUM_CLASS) {
descriptor.enumEntries.mapTo(methods) {
ObjCGetterForKotlinEnumEntry(symbolTable.referenceEnumEntry(it))
}
@@ -381,6 +381,7 @@ func testClassInstances() throws {
}
func testEnum() throws {
try assertEquals(actual: ValuesKt.passEnum(), expected: Enumeration.answer)
try assertEquals(actual: ValuesKt.passEnum().enumValue, expected: 42)
try assertEquals(actual: ValuesKt.passEnum().name, expected: "ANSWER")
ValuesKt.receiveEnum(e: 1)