Commit 9c248189 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

jscript: Added delete expression for EXPRVAL_IDREF implementation.

parent 65a20746
......@@ -2069,6 +2069,17 @@ HRESULT delete_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWORD flags
return hres;
switch(exprval.type) {
case EXPRVAL_IDREF: {
IDispatchEx *dispex;
hres = IDispatch_QueryInterface(exprval.u.nameref.disp, &IID_IDispatchEx, (void**)&dispex);
if(SUCCEEDED(hres)) {
hres = IDispatchEx_DeleteMemberByDispID(dispex, exprval.u.idref.id);
b = VARIANT_TRUE;
IDispatchEx_Release(dispex);
}
break;
}
case EXPRVAL_NAMEREF: {
IDispatchEx *dispex;
......
......@@ -741,4 +741,11 @@ function varTestFunc(varTest3) {
var varTest4;
}
deleteTest = 1;
delete deleteTest;
try {
tmp = deleteTest;
ok(false, "deleteTest not throwed exception?");
}catch(ex) {}
reportSuccess();
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment