Commit 609e9de6 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

jscript: Introduce INVALID_LOCAL_REF.

parent 7ba144b4
......@@ -2314,6 +2314,7 @@ static HRESULT compile_function(compiler_ctx_t *ctx, source_elements_t *source,
TRACE("\n");
func->bytecode = ctx->code;
func->local_ref = INVALID_LOCAL_REF;
ctx->func_head = ctx->func_tail = NULL;
ctx->from_eval = from_eval;
ctx->func = func;
......
......@@ -3039,7 +3039,7 @@ static HRESULT setup_scope(script_ctx_t *ctx, call_frame_t *frame, scope_chain_t
}
for(i = 0; i < frame->function->func_cnt; i++) {
if(frame->function->funcs[i].name && !frame->function->funcs[i].event_target) {
if(frame->function->funcs[i].local_ref != INVALID_LOCAL_REF) {
jsdisp_t *func_obj;
unsigned off;
......
......@@ -145,6 +145,8 @@ typedef struct {
int ref;
} local_ref_t;
#define INVALID_LOCAL_REF 0x7fffffff
typedef struct _function_code_t {
BSTR name;
int local_ref;
......
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