summaryrefslogtreecommitdiff
path: root/tests/structs/bug686190.vala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/structs/bug686190.vala')
-rw-r--r--tests/structs/bug686190.vala14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/structs/bug686190.vala b/tests/structs/bug686190.vala
new file mode 100644
index 000000000..4d26975bf
--- /dev/null
+++ b/tests/structs/bug686190.vala
@@ -0,0 +1,14 @@
+struct Foo {
+ int x;
+
+ public void meth () {
+ x = 10;
+ }
+}
+
+void main () {
+ Foo foo = Foo ();
+ Foo* bar = &foo;
+ bar.meth ();
+ assert (foo.x == 10);
+}