jscript: Use bytecode for labelled statement stub.

oldstable
Jacek Caban 2011-12-27 11:16:51 +01:00 committed by Alexandre Julliard
parent c57dd899a4
commit a6530f4032
4 changed files with 5 additions and 3 deletions

View File

@ -1246,6 +1246,8 @@ static HRESULT compile_statement(compiler_ctx_t *ctx, statement_t *stat)
return compile_for_statement(ctx, (for_statement_t*)stat);
case STAT_IF:
return compile_if_statement(ctx, (if_statement_t*)stat);
case STAT_LABEL:
return push_instr(ctx, OP_label) == -1 ? E_OUTOFMEMORY : S_OK; /* FIXME */
case STAT_SWITCH:
return compile_switch_statement(ctx, (switch_statement_t*)stat);
case STAT_VAR:

View File

@ -1067,7 +1067,7 @@ HRESULT interp_pop_scope(exec_ctx_t *ctx)
}
/* ECMA-262 3rd Edition 12.12 */
HRESULT labelled_statement_eval(script_ctx_t *ctx, statement_t *stat, return_type_t *rt, VARIANT *ret)
HRESULT interp_label(exec_ctx_t *ctx)
{
FIXME("\n");
return E_NOTIMPL;

View File

@ -71,6 +71,7 @@ typedef struct _func_stack {
X(int, 1, ARG_INT, 0) \
X(jmp, 0, ARG_ADDR, 0) \
X(jmp_z, 0, ARG_ADDR, 0) \
X(label, 0, 0,0) \
X(lshift, 1, 0,0) \
X(lt, 1, 0,0) \
X(lteq, 1, 0,0) \
@ -410,7 +411,6 @@ HRESULT continue_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIAN
HRESULT break_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;
HRESULT return_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;
HRESULT with_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;
HRESULT labelled_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;
HRESULT switch_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;
HRESULT throw_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;
HRESULT try_statement_eval(script_ctx_t*,statement_t*,return_type_t*,VARIANT*) DECLSPEC_HIDDEN;

View File

@ -844,7 +844,7 @@ static const statement_eval_t stat_eval_table[] = {
compiled_statement_eval,
forin_statement_eval,
compiled_statement_eval,
labelled_statement_eval,
compiled_statement_eval,
return_statement_eval,
compiled_statement_eval,
throw_statement_eval,