Commit 80113b5c authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

jscript: Use labels in compiler for ending loops.

parent 3b56e49e
......@@ -1351,6 +1351,9 @@ static HRESULT interp_push_except(exec_ctx_t *ctx)
hres = stack_push_bool(ctx, TRUE);
if(FAILED(hres))
return hres;
hres = stack_push_bool(ctx, TRUE);
if(FAILED(hres))
return hres;
}
except = heap_alloc(sizeof(*except));
......@@ -1400,8 +1403,8 @@ static HRESULT interp_end_finally(exec_ctx_t *ctx)
return DISP_E_EXCEPTION;
}
*stack_top(ctx) = *v;
return S_OK;
stack_popn(ctx, 2);
return stack_push(ctx, v);
}
/* ECMA-262 3rd Edition 13 */
......
......@@ -62,7 +62,7 @@ typedef struct _func_stack {
X(end_finally,1, 0,0) \
X(eq, 1, 0,0) \
X(eq2, 1, 0,0) \
X(forin, 0, ARG_UINT, 0) \
X(forin, 0, ARG_ADDR, 0) \
X(func, 1, ARG_FUNC, 0) \
X(gt, 1, 0,0) \
X(gteq, 1, 0,0) \
......@@ -95,7 +95,7 @@ typedef struct _func_stack {
X(pop_scope, 1, 0,0) \
X(postinc, 1, ARG_INT, 0) \
X(preinc, 1, ARG_INT, 0) \
X(push_except,1, ARG_UINT, ARG_BSTR) \
X(push_except,1, ARG_ADDR, ARG_BSTR) \
X(push_scope, 1, 0,0) \
X(regexp, 1, ARG_STR, ARG_INT) \
X(rshift, 1, 0,0) \
......@@ -139,10 +139,12 @@ typedef enum {
ARG_NONE = 0,
ARG_ADDR,
ARG_BSTR,
ARG_DBL,
ARG_STAT,
ARG_FUNC,
ARG_INT,
ARG_STR
ARG_STR,
ARG_UINT
} instr_arg_type_t;
typedef struct {
......
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