vala r946 - in trunk: . vala
- From: juergbi svn gnome org
 
- To: svn-commits-list gnome org
 
- Subject: vala r946 - in trunk: . vala
 
- Date: Fri,  1 Feb 2008 18:44:57 +0000 (GMT)
 
Author: juergbi
Date: Fri Feb  1 18:44:56 2008
New Revision: 946
URL: http://svn.gnome.org/viewvc/vala?rev=946&view=rev
Log:
2008-02-01  Juerg Billeter  <j bitron ch>
	* vala/valasemanticanalyzer.vala: report error for binary
	  expressions with invalid operands, fixes bug 513708
Modified:
   trunk/ChangeLog
   trunk/vala/valasemanticanalyzer.vala
Modified: trunk/vala/valasemanticanalyzer.vala
==============================================================================
--- trunk/vala/valasemanticanalyzer.vala	(original)
+++ trunk/vala/valasemanticanalyzer.vala	Fri Feb  1 18:44:56 2008
@@ -2369,7 +2369,13 @@
 		}
 
 		if (expr.left.static_type == null) {
-			Report.error (expr.source_reference, "invalid operand");
+			Report.error (expr.left.source_reference, "invalid left operand");
+			expr.error = true;
+			return;
+		}
+
+		if (expr.operator != BinaryOperator.IN && expr.right.static_type == null) {
+			Report.error (expr.right.source_reference, "invalid right operand");
 			expr.error = true;
 			return;
 		}
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]