From 5f57ba54a40f3b902422bf54f6238e26715abab1 Mon Sep 17 00:00:00 2001 From: belliash Date: Wed, 17 Apr 2019 08:59:42 +0200 Subject: [PATCH] Left operand must be modifiable when storing some value. --- engine/parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/engine/parser.c b/engine/parser.c index b6e8aac..550808f 100644 --- a/engine/parser.c +++ b/engine/parser.c @@ -1419,7 +1419,7 @@ static sxi32 ExprMakeTree(ph7_gen_state *pGen, ph7_expr_node **apNode, sxi32 nTo return rc; } if(ExprIsModifiableValue(apNode[iLeft], FALSE) == FALSE) { - if(pNode->pOp->iVmOp != PH7_OP_STORE) { + if(pNode->pOp->iVmOp == PH7_OP_STORE) { /* Left operand must be a modifiable l-value */ rc = PH7_GenCompileError(pGen, E_ERROR, pNode->pStart->nLine, "'%z': Left operand must be a modifiable l-value", &pNode->pOp->sOp);