Temporary workaround (until parser is refactored) for fixing parse of expressions like '1 = 1'.

JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
This commit is contained in:
Ruben Ayrapetyan 2015-07-13 21:22:57 +03:00 committed by Evgeny Gavrin
parent 44b7b95781
commit 7bc2c69147

View File

@ -658,6 +658,15 @@ dump_prop_setter_or_triple_address_res (void (*dumper) (operand, operand, operan
}
else
{
if (res.type == OPERAND_TMP)
{
/*
* FIXME:
* Implement correct handling of references through parser operands
*/
PARSE_ERROR (JSP_EARLY_ERROR_REFERENCE, "Invalid left-hand-side expression", LIT_ITERATOR_POS_ZERO);
}
dumper (res, res, op);
}
STACK_DROP (prop_getters, 1);
@ -2072,6 +2081,14 @@ dump_prop_setter_or_variable_assignment_res (operand res, operand op)
}
else
{
if (res.type == OPERAND_TMP)
{
/*
* FIXME:
* Implement correct handling of references through parser operands
*/
PARSE_ERROR (JSP_EARLY_ERROR_REFERENCE, "Invalid left-hand-side expression", LIT_ITERATOR_POS_ZERO);
}
dump_variable_assignment (res, op);
}
STACK_DROP (prop_getters, 1);