Commit 3c366be3 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

vbscript: Lookup this object in lookup_identifier only if it's an actual VBScript object.

parent 50904429
......@@ -139,14 +139,14 @@ static HRESULT lookup_identifier(exec_ctx_t *ctx, BSTR name, vbdisp_invoke_type_
return S_OK;
}
}
}
hres = disp_get_id(ctx->this_obj, name, invoke_type, TRUE, &id);
if(SUCCEEDED(hres)) {
ref->type = REF_DISP;
ref->u.d.disp = ctx->this_obj;
ref->u.d.id = id;
return S_OK;
hres = vbdisp_get_id(ctx->vbthis, name, invoke_type, TRUE, &id);
if(SUCCEEDED(hres)) {
ref->type = REF_DISP;
ref->u.d.disp = (IDispatch*)&ctx->vbthis->IDispatchEx_iface;
ref->u.d.id = id;
return S_OK;
}
}
}
......
......@@ -3025,6 +3025,12 @@ static void run_tests(void)
parse_script_a("testOptionalArg 1,,2");
CHECK_CALLED(global_testoptionalarg_i);
parse_script_a("sub x()\n"
" dim y\n"
" y = cint(3)\n"
"end sub\n"
"x\n");
strict_dispid_check = FALSE;
SET_EXPECT(testobj_value_i);
......
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