tests/benchmarks/qml/librarymetrics_performance/data/expression.2.qml
raw| 1 | import QtQuick 2.0 |
| 2 | |
| 3 | Item { |
| 4 | property int a: 0 |
| 5 | property int b: 0 |
| 6 | |
| 7 | function someFunc() { |
| 8 | var tmp = 5; |
| 9 | var another = tmp * 5 + 3; |
| 10 | var yetanother = another % 5; |
| 11 | if (yetanother > 2) a = 42; |
| 12 | else a = 9000; |
| 13 | return 42; |
| 14 | } |
| 15 | |
| 16 | Component.onCompleted: { |
| 17 | b = someFunc(); |
| 18 | } |
| 19 | } |