mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
Also in Nashorn everything has hashCode including primitive types, so the result can be different at Nashorn and at other engines.
8 lines
162 B
Kotlin
Vendored
8 lines
162 B
Kotlin
Vendored
data class A(val a: Boolean)
|
|
|
|
fun box() : String {
|
|
if (A(true).hashCode() != 1) return "fail1"
|
|
if (A(false).hashCode() !=0) return "fail2"
|
|
return "OK"
|
|
}
|