summaryrefslogtreecommitdiff
path: root/vala/valaswitchstatement.vala
diff options
context:
space:
mode:
authorLuca Bruno <lucabru@src.gnome.org>2011-08-03 17:07:58 +0200
committerLuca Bruno <lucabru@src.gnome.org>2011-08-03 20:48:13 +0200
commita2056afe1922280401a5a991428c9c4ba6edaf9a (patch)
treebadc2ddfdd284e9d789dfe2fca5b82a2bcf8cb15 /vala/valaswitchstatement.vala
parentd6a032ed5a3fcc5532ac5374a09644af80100f5c (diff)
downloadvala-a2056afe1922280401a5a991428c9c4ba6edaf9a.tar.gz
Set target_type of switch statement expression to be non-nullable
Fixes bug 655908.
Diffstat (limited to 'vala/valaswitchstatement.vala')
-rw-r--r--vala/valaswitchstatement.vala1
1 files changed, 1 insertions, 0 deletions
diff --git a/vala/valaswitchstatement.vala b/vala/valaswitchstatement.vala
index 6509d49f1..12ad04b89 100644
--- a/vala/valaswitchstatement.vala
+++ b/vala/valaswitchstatement.vala
@@ -116,6 +116,7 @@ public class Vala.SwitchStatement : CodeNode, Statement {
// ensure that possibly owned (string) expression stays alive
expression.target_type = expression.value_type.copy ();
+ expression.target_type.nullable = false;
var labelset = new HashSet<string> (str_hash, str_equal);
foreach (SwitchSection section in sections) {