Files
kotlin-fork/js/js.translator/testData/box/enum/nativeEnum.kt
T
Alexey Andreev 3b3fd0fa0d JS: fix DCE limits in test data to fit new kotlin.js size
The size has increased due to new implementation of KClass
2017-10-06 18:16:51 +03:00

19 lines
341 B
Kotlin
Vendored

// EXPECTED_REACHABLE_NODES: 1115
package foo
external enum class JsEnum {
Foo,
Bar,
Baz
}
// TODO uncomment when KT-5605 will be fixed
// fun JsEnum.extImplicit() = Foo
fun box(): String {
assertEquals(1, JsEnum.Foo)
assertEquals("BAR", JsEnum.Bar)
assertEquals("OK", JsEnum.Baz.asDynamic().ok)
return "OK"
}