]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
Mark the inner expression of unary increment/decrement to be lvalue
authorLuca Bruno <lucabru@src.gnome.org>
Mon, 2 May 2011 13:31:43 +0000 (15:31 +0200)
committerLuca Bruno <lucabru@src.gnome.org>
Mon, 2 May 2011 13:31:43 +0000 (15:31 +0200)
vala/valaunaryexpression.vala

index 930e5ce06bcec11e6955292cddbd62e66e220fc2..a26c3dac40b4b33dd4f0002effd533d259248ae2 100644 (file)
@@ -156,6 +156,8 @@ public class Vala.UnaryExpression : Expression {
                if (operator == UnaryOperator.REF || operator == UnaryOperator.OUT) {
                        inner.lvalue = true;
                        inner.target_type = target_type;
+               } else if (operator == UnaryOperator.INCREMENT || operator == UnaryOperator.DECREMENT) {
+                       inner.lvalue = true;
                }
 
                if (!inner.check (context)) {