// Copyright © SixtyFPS GmbH // SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-commercial Comp := Rectangle { function f1() {} public function f2() {} } export Xxx := Rectangle { function foo(a: int) -> string { return a; } comp := Comp {} function bar() { foo(45, 45); // ^error{The callback or function expects 1 arguments, but 2 are provided} foo.hello(45); // ^error{Cannot access fields of a function} root.foo(); // ^error{The callback or function expects 1 arguments, but 0 are provided} root.foo.hello(45); // ^error{Cannot access fields of a function} comp.f1(); // ^error{The function 'f1' is private. Annotate it with 'public' to make it accessible from other components} comp.f2(); } callback xx <=> foo; // ^error{Binding to callback 'xx' must bind to another callback} }