From 5ee8ced9cde62013fec4fb8e0ffc97d5f31cbd0e Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=BCrg=20Billeter?= Date: Sat, 20 Mar 2010 17:05:24 +0100 Subject: [PATCH] Improve error reporting for local variable initializers --- vala/valalocalvariable.vala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vala/valalocalvariable.vala b/vala/valalocalvariable.vala index 917e4b76b..72dbe8371 100644 --- a/vala/valalocalvariable.vala +++ b/vala/valalocalvariable.vala @@ -1,6 +1,6 @@ /* valalocalvariable.vala * - * Copyright (C) 2006-2009 Jürg Billeter + * Copyright (C) 2006-2010 Jürg Billeter * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -148,7 +148,7 @@ public class Vala.LocalVariable : Symbol { initializer.target_type = variable_type; } - if (initializer != null) { + if (initializer != null && !initializer.error) { if (initializer.value_type == null) { if (!(initializer is MemberAccess) && !(initializer is LambdaExpression)) { error = true; -- 2.47.3