1// Copyright © SixtyFPS GmbH <info@slint.dev>
2// SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0
3
4// From issue #737
5
6Key := Rectangle { property <int> pos; property <int> num_elements; }
7
8export Test := Rectangle {
9 Rectangle {
10 property <int> num_elements;
11 num-elements: 4;
12 Key { pos: 1; num_elements: num_elements; }
13 // ^error{The binding for the property 'num-elements' is part of a binding loop}
14 Key { pos: 2; num_elements: self.num_elements; }
15 // ^error{The binding for the property 'num-elements' is part of a binding loop}
16 Key { pos: 3; num_elements: parent.num_elements; }
17 Key { pos: 4; num_elements: num_elements; }
18 // ^error{The binding for the property 'num-elements' is part of a binding loop}
19 }
20}
21