/* LICENSE BEGIN This file is part of the SixtyFPS Project -- https://sixtyfps.io Copyright (c) 2021 Olivier Goffart Copyright (c) 2021 Simon Hausmann SPDX-License-Identifier: GPL-3.0-only This file is also available under commercial licensing terms. Please contact info@sixtyfps.io for more information. LICENSE END */ // This tests that constant property from global are properly initialized global Glob := { property a: 3; property b: a + 3; } global Glob2 := { property a: other; property other: 5; } TestCase := Rectangle { r := Rectangle { property value1: Glob.b; property value2: true ? Glob2.a : 88; } property test: r.value1 + r.value2 == 3+3 +5; } /* ```rust let instance = TestCase::new(); assert!(instance.get_test()); ``` ```cpp auto handle = TestCase::create(); const TestCase &instance = *handle; assert(instance.get_test()); ``` ```js let instance = new sixtyfps.TestCase({}); assert(instance.test); ``` */