mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-01 14:21:16 +00:00

This also start parsing assignment ('=') as a self assignement but the code generation is not yet implmented
23 lines
542 B
Text
23 lines
542 B
Text
SuperSimple := Rectangle {
|
|
TouchArea {
|
|
clicked => { root.x += 1px; }
|
|
}
|
|
TouchArea {
|
|
clicked => { x += 1px; }
|
|
}
|
|
TouchArea {
|
|
clicked => { 12 += 1; }
|
|
// ^error{Self assignement need to be done on a property}
|
|
}
|
|
TouchArea {
|
|
clicked => { x += "string"; }
|
|
// ^error{Cannot convert string to length}
|
|
}
|
|
|
|
TouchArea {
|
|
clicked => { doesnotexist += 24; }
|
|
// ^error{Unknown unqualified identifier 'doesnotexist'}
|
|
}
|
|
|
|
}
|
|
|