From ec429ac39356f40ef853535d9a8a3d19b1e2eca4 Mon Sep 17 00:00:00 2001 From: Juerg Billeter Date: Fri, 27 Jul 2007 13:23:20 +0000 Subject: [PATCH] fix warning when connecting signals 2007-07-27 Juerg Billeter * vala/valasemanticanalyzer.vala: fix warning when connecting signals svn path=/trunk/; revision=404 --- ChangeLog | 4 ++++ vala/valasemanticanalyzer.vala | 12 ++++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 83996fb..ae11f57 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2007-07-27 Jürg Billeter + * vala/valasemanticanalyzer.vala: fix warning when connecting signals + +2007-07-27 Jürg Billeter + * vala/valasemanticanalyzer.vala: fix warning when using element access with Gee.List or Gee.Map diff --git a/vala/valasemanticanalyzer.vala b/vala/valasemanticanalyzer.vala index 42e7d17..1a3310c 100644 --- a/vala/valasemanticanalyzer.vala +++ b/vala/valasemanticanalyzer.vala @@ -2567,10 +2567,14 @@ public class Vala.SemanticAnalyzer : CodeVisitor { return; } - a.static_type = a.left.static_type.copy (); - if (a.parent_node is ExpressionStatement) { - // Gee.List.get () transfers ownership but void function Gee.List.set () doesn't - a.static_type.transfers_ownership = false; + if (a.left.static_type != null) { + a.static_type = a.left.static_type.copy (); + if (a.parent_node is ExpressionStatement) { + // Gee.List.get () transfers ownership but void function Gee.List.set () doesn't + a.static_type.transfers_ownership = false; + } + } else { + a.static_type = null; } } } -- 2.7.4