slint/sixtyfps_compiler/tests/basic/self_assign.60
2020-06-12 10:32:56 +02:00

17 lines
397 B
Text

SuperSimple := Rectangle {
TouchArea {
clicked => { root.x += 1; }
}
TouchArea {
clicked => { x += 1; }
}
TouchArea {
clicked => { 12 += 1; }
// ^error{Self assignement need to be done on a property}
}
TouchArea {
clicked => { x += "string"; }
// ^error{Cannot convert string to float32}
}
}