b79719d6f5
- Materialize unit when its value is actually needed. - Special-case Unit_getInstance return type at codegen. It should be a proper Unit object instead of a "void"
12 lines
170 B
Kotlin
Vendored
12 lines
170 B
Kotlin
Vendored
fun box(): String {
|
|
Unit
|
|
|
|
val a = Unit
|
|
val b = Unit
|
|
if (a != b) return "Fail a != b"
|
|
|
|
if (Unit != Unit) return "Fail Unit != Unit"
|
|
|
|
return "OK"
|
|
}
|