summaryrefslogtreecommitdiff
path: root/tests/gtktemplate/gtkchild-field-out-assignment.test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/gtktemplate/gtkchild-field-out-assignment.test')
-rw-r--r--tests/gtktemplate/gtkchild-field-out-assignment.test17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/gtktemplate/gtkchild-field-out-assignment.test b/tests/gtktemplate/gtkchild-field-out-assignment.test
new file mode 100644
index 000000000..3f82f4251
--- /dev/null
+++ b/tests/gtktemplate/gtkchild-field-out-assignment.test
@@ -0,0 +1,17 @@
+Invalid Code
+
+[GtkTemplate (ui = "/org/example/gtktemplate.ui")]
+public class GtkTemplate : Gtk.ApplicationWindow {
+ [GtkChild]
+ public unowned Gtk.Button button0;
+
+ void foo () {
+ bar (out button0);
+ }
+
+ void bar (out unowned Gtk.Button b) {
+ }
+}
+
+void main () {
+}