ref: 62c6e3f62cf79731d34d25bb2a96c14352099856
parent: 543115ba39599d7cc5349cc76997b683d8a129b1
author: Tor Andersson <tor.andersson@artifex.com>
date: Wed Jan 7 16:33:44 EST 2015
strict mode: No delete operator with an unqualified name. delete is only allowed on x.y and x[y].
--- a/jscompile.c
+++ b/jscompile.c
@@ -420,6 +420,8 @@
{
switch (exp->type) {
case EXP_IDENTIFIER:
+ if (J->strict)
+ jsC_error(J, exp, "delete on an unqualified name is not allowed in strict mode");
emitlocal(J, F, OP_DELLOCAL, OP_DELVAR, exp->string);
break;
case EXP_INDEX: