diff options
author | Luca Bruno <lucabru@src.gnome.org> | 2014-09-09 20:31:10 +0200 |
---|---|---|
committer | Luca Bruno <lucabru@src.gnome.org> | 2014-09-09 20:31:12 +0200 |
commit | 962c2ece5915345fd6d9ac9f97919373e204fba7 (patch) | |
tree | 6320297da153719c7bb4cf04341693cc58242b6b | |
parent | 6146ea7d506ab4005e048ef85a701c98f5415406 (diff) | |
download | vala-962c2ece5915345fd6d9ac9f97919373e204fba7.tar.gz |
Resolve symbols in named arguments
Fixes bug 736235
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | tests/Makefile.am | 1 | ||||
-rw-r--r-- | tests/methods/bug736235.vala | 10 | ||||
-rw-r--r-- | vala/valasymbolresolver.vala | 4 |
4 files changed, 17 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore index 9373d2156..f0a229002 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 07c98772d..85ca6b351 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 000000000..bdbeb9b57 --- /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 94858e33b..32c84e4c3 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); } |