[vala] Resolve symbols in named arguments
- From: Luca Bruno <lucabru src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] Resolve symbols in named arguments
- Date: Tue, 9 Sep 2014 18:31:55 +0000 (UTC)
commit 962c2ece5915345fd6d9ac9f97919373e204fba7
Author: Luca Bruno <lucabru src gnome org>
Date: Tue Sep 9 20:31:10 2014 +0200
Resolve symbols in named arguments
Fixes bug 736235
.gitignore | 2 ++
tests/Makefile.am | 1 +
tests/methods/bug736235.vala | 10 ++++++++++
vala/valasymbolresolver.vala | 4 ++++
4 files changed, 17 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 9373d21..f0a2290 100644
--- a/.gitignore
+++ b/.gitignore
@@ -38,3 +38,5 @@ lcov.info
build-aux/test-driver
+tests/_test
+
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 07c9877..85ca6b3 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -62,6 +62,7 @@ TESTS = \
methods/bug723009.vala \
methods/bug723195.vala \
methods/bug726347.vala \
+ methods/bug736235.vala \
methods/generics.vala \
control-flow/break.vala \
control-flow/expressions-conditional.vala \
diff --git a/tests/methods/bug736235.vala b/tests/methods/bug736235.vala
new file mode 100644
index 0000000..bdbeb9b
--- /dev/null
+++ b/tests/methods/bug736235.vala
@@ -0,0 +1,10 @@
+public class Foo : GLib.Object {
+ public string? bar { get; construct; }
+
+ public Foo () {
+ GLib.Object (bar: (string?) null);
+ }
+}
+
+void main () {
+}
\ No newline at end of file
diff --git a/vala/valasymbolresolver.vala b/vala/valasymbolresolver.vala
index 94858e3..32c84e4 100644
--- a/vala/valasymbolresolver.vala
+++ b/vala/valasymbolresolver.vala
@@ -511,6 +511,10 @@ public class Vala.SymbolResolver : CodeVisitor {
expr.accept_children (this);
}
+ public override void visit_named_argument (NamedArgument expr) {
+ expr.accept_children (this);
+ }
+
public override void visit_addressof_expression (AddressofExpression expr) {
expr.accept_children (this);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]