StackValue.Property also needs to implement dupReceiver()

This commit is contained in:
Dmitry Jemerov
2011-06-17 17:24:14 +02:00
parent 6e1d79e5e1
commit 1816ff7c76
3 changed files with 30 additions and 0 deletions
@@ -0,0 +1,14 @@
class Slot() {
var vitality: Int = 10000
fun increaseVitality(delta: Int) {
vitality += delta
if (vitality > 65535) vitality = 65535;
}
}
fun box(): String {
val s = Slot()
s.increaseVitality(1000)
return if (s.vitality == 11000) "OK" else "fail"
}