[KT-4124] Fix some tests from common testData
This commit is contained in:
+13
-13
@@ -1,17 +1,17 @@
|
||||
package mult_constructors_3_bug
|
||||
// TODO: Enable for JS when it supports Java class library.
|
||||
// TARGET_BACKEND: JVM
|
||||
import java.util.HashMap
|
||||
import java.io.*
|
||||
|
||||
public open class Identifier() {
|
||||
private var myNullable : Boolean = true
|
||||
companion object {
|
||||
open public fun init(isNullable : Boolean) : Identifier {
|
||||
val id = Identifier()
|
||||
id.myNullable = isNullable
|
||||
return id
|
||||
}
|
||||
}
|
||||
}
|
||||
operator fun <K, V> MutableMap<K, V>.set(key : K, value : V) = put(key, value)
|
||||
|
||||
fun box() : String {
|
||||
Identifier.init(true)
|
||||
return "OK"
|
||||
|
||||
val commands : MutableMap<String, String> = HashMap()
|
||||
|
||||
commands["c1"] = "239"
|
||||
if(commands["c1"] != "239") return "fail"
|
||||
|
||||
commands["c1"] += "932"
|
||||
return if(commands["c1"] == "239932") "OK" else "fail"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user