Github User Fetcher 1.0.0
C Application with Server and GUI
|
#include "duk_internal.h"
Go to the source code of this file.
Data Structures | |
struct | duk__compiler_stkstate |
Macros | |
#define | DUK__CONST_MARKER DUK_JS_CONST_MARKER |
#define | DUK__MAX_ARRAY_INIT_VALUES 20 |
#define | DUK__MAX_OBJECT_INIT_PAIRS 10 |
#define | DUK__GETCONST_MAX_CONSTS_CHECK 256 |
#define | DUK__MAX_CONSTS DUK_BC_BC_MAX |
#define | DUK__MAX_FUNCS DUK_BC_BC_MAX |
#define | DUK__MAX_TEMPS 0xffffL |
#define | DUK__BC_INITIAL_INSTS 256 |
#define | DUK__RECURSION_INCREASE(comp_ctx, thr) |
#define | DUK__RECURSION_DECREASE(comp_ctx, thr) |
#define | DUK__COMPILE_ENTRY_SLOTS 8 |
#define | DUK__FUNCTION_INIT_REQUIRE_SLOTS 16 |
#define | DUK__FUNCTION_BODY_REQUIRE_SLOTS 16 |
#define | DUK__PARSE_STATEMENTS_SLOTS 16 |
#define | DUK__PARSE_EXPR_SLOTS 16 |
#define | DUK__BP_INVALID 0 /* always terminates led() */ |
#define | DUK__BP_EOF 2 |
#define | DUK__BP_CLOSING 4 /* token closes expression, e.g. ')', ']' */ |
#define | DUK__BP_FOR_EXPR DUK__BP_CLOSING /* bp to use when parsing a top level Expression */ |
#define | DUK__BP_COMMA 6 |
#define | DUK__BP_ASSIGNMENT 8 |
#define | DUK__BP_CONDITIONAL 10 |
#define | DUK__BP_LOR 12 |
#define | DUK__BP_LAND 14 |
#define | DUK__BP_BOR 16 |
#define | DUK__BP_BXOR 18 |
#define | DUK__BP_BAND 20 |
#define | DUK__BP_EQUALITY 22 |
#define | DUK__BP_RELATIONAL 24 |
#define | DUK__BP_SHIFT 26 |
#define | DUK__BP_ADDITIVE 28 |
#define | DUK__BP_MULTIPLICATIVE 30 |
#define | DUK__BP_POSTFIX 32 |
#define | DUK__BP_CALL 34 |
#define | DUK__BP_MEMBER 36 |
#define | DUK__TOKEN_LBP_BP_MASK 0x1f |
#define | DUK__TOKEN_LBP_FLAG_NO_REGEXP (1 << 5) /* regexp literal must not follow this token */ |
#define | DUK__TOKEN_LBP_FLAG_TERMINATES (1 << 6) /* terminates expression; e.g. post-increment/-decrement */ |
#define | DUK__TOKEN_LBP_FLAG_UNUSED (1 << 7) /* spare */ |
#define | DUK__TOKEN_LBP_GET_BP(x) ((duk_small_uint_t) (((x) & DUK__TOKEN_LBP_BP_MASK) * 2)) |
#define | DUK__MK_LBP(bp) ((bp) >> 1) /* bp is assumed to be even */ |
#define | DUK__MK_LBP_FLAGS(bp, flags) (((bp) >> 1) | (flags)) |
#define | DUK__EMIT_FLAG_NO_SHUFFLE_A (1 << 8) |
#define | DUK__EMIT_FLAG_NO_SHUFFLE_B (1 << 9) |
#define | DUK__EMIT_FLAG_NO_SHUFFLE_C (1 << 10) |
#define | DUK__EMIT_FLAG_A_IS_SOURCE (1 << 11) /* slot A is a source (default: target) */ |
#define | DUK__EMIT_FLAG_B_IS_TARGET (1 << 12) /* slot B is a target (default: source) */ |
#define | DUK__EMIT_FLAG_C_IS_TARGET (1 << 13) /* slot C is a target (default: source) */ |
#define | DUK__EMIT_FLAG_B_IS_TARGETSOURCE (1 << 14) /* slot B is both a target and a source (used by extraops like DUK_EXTRAOP_INSTOF */ |
#define | DUK__EMIT_FLAG_RESERVE_JUMPSLOT (1 << 15) /* reserve a jumpslot after instr before target spilling, used for NEXTENUM */ |
#define | DUK__ISREG(comp_ctx, x) (((x) & DUK__CONST_MARKER) == 0) |
#define | DUK__ISCONST(comp_ctx, x) (((x) & DUK__CONST_MARKER) != 0) |
#define | DUK__ISTEMP(comp_ctx, x) (DUK__ISREG((comp_ctx), (x)) && (duk_regconst_t) (x) >= (duk_regconst_t) ((comp_ctx)->curr_func.temp_first)) |
#define | DUK__GETTEMP(comp_ctx) ((comp_ctx)->curr_func.temp_next) |
#define | DUK__SETTEMP(comp_ctx, x) ((comp_ctx)->curr_func.temp_next = (x)) /* dangerous: must only lower (temp_max not updated) */ |
#define | DUK__SETTEMP_CHECKMAX(comp_ctx, x) duk__settemp_checkmax((comp_ctx),(x)) |
#define | DUK__ALLOCTEMP(comp_ctx) duk__alloctemp((comp_ctx)) |
#define | DUK__ALLOCTEMPS(comp_ctx, count) duk__alloctemps((comp_ctx),(count)) |
#define | DUK__IVAL_FLAG_ALLOW_CONST (1 << 0) /* allow a constant to be returned */ |
#define | DUK__IVAL_FLAG_REQUIRE_TEMP (1 << 1) /* require a (mutable) temporary as a result (or a const if allowed) */ |
#define | DUK__IVAL_FLAG_REQUIRE_SHORT (1 << 2) /* require a short (8-bit) reg/const which fits into bytecode B/C slot */ |
#define | DUK__DUMP_ISPEC(comp_ctx, x) do {} while (0) |
#define | DUK__DUMP_IVALUE(comp_ctx, x) do {} while (0) |
#define | DUK__OBJ_LIT_KEY_PLAIN (1 << 0) /* key encountered as a plain property */ |
#define | DUK__OBJ_LIT_KEY_GET (1 << 1) /* key encountered as a getter */ |
#define | DUK__OBJ_LIT_KEY_SET (1 << 2) /* key encountered as a setter */ |
#define | DUK__EXPR_RBP_MASK 0xff |
#define | DUK__EXPR_FLAG_REJECT_IN (1 << 8) /* reject 'in' token (used for for-in) */ |
#define | DUK__EXPR_FLAG_ALLOW_EMPTY (1 << 9) /* allow empty expression */ |
#define | DUK__EXPR_FLAG_REQUIRE_INIT (1 << 10) /* require initializer for var/const */ |
#define | DUK__HAS_VAL (1 << 0) /* stmt has non-empty value */ |
#define | DUK__HAS_TERM (1 << 1) /* stmt has explicit/implicit semicolon terminator */ |
#define | DUK__ALLOW_AUTO_SEMI_ALWAYS (1 << 2) /* allow automatic semicolon even without lineterm (compatibility) */ |
#define | DUK__STILL_PROLOGUE (1 << 3) /* statement does not terminate directive prologue */ |
#define | DUK__IS_TERMINAL (1 << 4) /* statement is guaranteed to be terminal (control doesn't flow to next statement) */ |
Variables | |
DUK_LOCAL const duk_uint8_t | duk__token_lbp [] |
#define DUK__ALLOCTEMP | ( | comp_ctx | ) | duk__alloctemp((comp_ctx)) |
Definition at line 1778 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__expr_nud(), duk__init_varmap_and_prologue_for_pass2(), duk__ispec_toregconst_raw(), duk__ivalue_toplain_raw(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_arguments(), duk__parse_func_body(), and duk__parse_switch_stmt().
#define DUK__ALLOCTEMPS | ( | comp_ctx, | |
count ) duk__alloctemps((comp_ctx),(count)) |
Definition at line 1779 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__init_varmap_and_prologue_for_pass2(), duk__parse_for_stmt(), duk__parse_try_stmt(), and duk__parse_with_stmt().
#define DUK__ALLOW_AUTO_SEMI_ALWAYS (1 << 2) /* allow automatic semicolon even without lineterm (compatibility) */ |
Definition at line 4954 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmt().
#define DUK__BC_INITIAL_INSTS 256 |
Definition at line 49 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__init_func_valstack_slots().
#define DUK__BP_ADDITIVE 28 |
Definition at line 257 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_ASSIGNMENT 8 |
Definition at line 247 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_BAND 20 |
Definition at line 253 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_BOR 16 |
Definition at line 251 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_BXOR 18 |
Definition at line 252 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_CALL 34 |
Definition at line 260 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_nud().
#define DUK__BP_CLOSING 4 /* token closes expression, e.g. ')', ']' */ |
Definition at line 244 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__BP_COMMA 6 |
Definition at line 246 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_arguments(), and duk__parse_var_decl().
#define DUK__BP_CONDITIONAL 10 |
Definition at line 248 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__BP_EOF 2 |
Definition at line 243 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__BP_EQUALITY 22 |
Definition at line 254 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_FOR_EXPR DUK__BP_CLOSING /* bp to use when parsing a top level Expression */ |
Definition at line 245 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__expr_nud(), duk__parse_do_stmt(), duk__parse_for_stmt(), duk__parse_if_stmt(), duk__parse_return_stmt(), duk__parse_stmt(), duk__parse_switch_stmt(), duk__parse_throw_stmt(), duk__parse_while_stmt(), and duk__parse_with_stmt().
#define DUK__BP_INVALID 0 /* always terminates led() */ |
Definition at line 242 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__BP_LAND 14 |
Definition at line 250 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_LOR 12 |
Definition at line 249 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_MEMBER 36 |
Definition at line 261 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__BP_MULTIPLICATIVE 30 |
Definition at line 258 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), and duk__expr_nud().
#define DUK__BP_POSTFIX 32 |
Definition at line 259 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__BP_RELATIONAL 24 |
Definition at line 255 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__BP_SHIFT 26 |
Definition at line 256 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led().
#define DUK__COMPILE_ENTRY_SLOTS 8 |
Definition at line 64 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__js_compile_raw().
#define DUK__CONST_MARKER DUK_JS_CONST_MARKER |
Definition at line 32 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_abc(), duk__expr_led(), duk__getconst(), duk__ispec_toregconst_raw(), and duk__patch_trycatch().
#define DUK__DUMP_ISPEC | ( | comp_ctx, | |
x ) do {} while (0) |
Definition at line 1811 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__DUMP_IVALUE | ( | comp_ctx, | |
x ) do {} while (0) |
Definition at line 1812 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Definition at line 1007 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), duk__emit_a_bc(), duk__expr_led(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_for_stmt(), duk__parse_try_stmt(), and duk__parse_var_decl().
Definition at line 1008 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), duk__expr_nud(), duk__ivalue_toplain_raw(), duk__nud_array_literal(), duk__nud_object_literal(), and duk__parse_for_stmt().
#define DUK__EMIT_FLAG_B_IS_TARGETSOURCE (1 << 14) /* slot B is both a target and a source (used by extraops like DUK_EXTRAOP_INSTOF */ |
Definition at line 1010 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), and duk__ivalue_toplain_raw().
Definition at line 1009 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c().
#define DUK__EMIT_FLAG_NO_SHUFFLE_A (1 << 8) |
Definition at line 1004 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_extraop_b(), duk__emit_extraop_b_c(), duk__emit_extraop_bc(), duk__emit_extraop_only(), duk__emit_if_false_skip(), duk__emit_if_true_skip(), duk__expr_led(), duk__expr_nud(), duk__init_varmap_and_prologue_for_pass2(), duk__parse_func_body(), duk__parse_return_stmt(), and duk__parse_with_stmt().
#define DUK__EMIT_FLAG_NO_SHUFFLE_B (1 << 9) |
Definition at line 1005 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), and duk__emit_extraop_only().
#define DUK__EMIT_FLAG_NO_SHUFFLE_C (1 << 10) |
Definition at line 1006 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b(), duk__emit_a_b_c(), duk__emit_extraop_only(), duk__emit_if_false_skip(), duk__emit_if_true_skip(), duk__expr_led(), duk__expr_nud(), duk__nud_array_literal(), and duk__nud_object_literal().
#define DUK__EMIT_FLAG_RESERVE_JUMPSLOT (1 << 15) /* reserve a jumpslot after instr before target spilling, used for NEXTENUM */ |
Definition at line 1011 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__emit_a_b_c(), and duk__parse_for_stmt().
#define DUK__EXPR_FLAG_ALLOW_EMPTY (1 << 9) /* allow empty expression */ |
Definition at line 4761 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr(), duk__exprtop(), and duk__parse_for_stmt().
#define DUK__EXPR_FLAG_REJECT_IN (1 << 8) /* reject 'in' token (used for for-in) */ |
Definition at line 4760 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__exprtop(), and duk__parse_for_stmt().
#define DUK__EXPR_FLAG_REQUIRE_INIT (1 << 10) /* require initializer for var/const */ |
Definition at line 4762 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmt(), and duk__parse_var_decl().
#define DUK__EXPR_RBP_MASK 0xff |
Definition at line 4759 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr().
#define DUK__FUNCTION_BODY_REQUIRE_SLOTS 16 |
Definition at line 66 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_func_body().
#define DUK__FUNCTION_INIT_REQUIRE_SLOTS 16 |
Definition at line 65 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__init_func_valstack_slots().
#define DUK__GETCONST_MAX_CONSTS_CHECK 256 |
Definition at line 39 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__getconst().
#define DUK__GETTEMP | ( | comp_ctx | ) | ((comp_ctx)->curr_func.temp_next) |
Definition at line 1775 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_nud(), duk__ivalue_toplain_ignore(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_for_stmt(), duk__parse_func_body(), duk__parse_if_stmt(), duk__parse_stmt(), duk__parse_switch_stmt(), and duk__parse_while_stmt().
#define DUK__HAS_TERM (1 << 1) /* stmt has explicit/implicit semicolon terminator */ |
Definition at line 4953 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmt().
#define DUK__HAS_VAL (1 << 0) /* stmt has non-empty value */ |
Definition at line 4952 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmt().
#define DUK__IS_TERMINAL (1 << 4) /* statement is guaranteed to be terminal (control doesn't flow to next statement) */ |
Definition at line 4956 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmt().
#define DUK__ISCONST | ( | comp_ctx, | |
x ) (((x) & DUK__CONST_MARKER) != 0) |
Definition at line 1773 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__ivalue_toplain_raw().
#define DUK__ISREG | ( | comp_ctx, | |
x ) (((x) & DUK__CONST_MARKER) == 0) |
Definition at line 1772 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__ivalue_toplain_raw().
#define DUK__ISTEMP | ( | comp_ctx, | |
x ) (DUK__ISREG((comp_ctx), (x)) && (duk_regconst_t) (x) >= (duk_regconst_t) ((comp_ctx)->curr_func.temp_first)) |
Definition at line 1774 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__ispec_toregconst_raw(), duk__ivalue_toplain_raw(), and duk__parse_return_stmt().
#define DUK__IVAL_FLAG_ALLOW_CONST (1 << 0) /* allow a constant to be returned */ |
Definition at line 1785 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__expr_nud(), duk__ispec_toregconst_raw(), duk__ivalue_toplain_raw(), duk__ivalue_toregconst(), duk__ivalue_toregconst_raw(), duk__ivalue_totempconst(), and duk__parse_for_stmt().
#define DUK__IVAL_FLAG_REQUIRE_SHORT (1 << 2) /* require a short (8-bit) reg/const which fits into bytecode B/C slot */ |
Definition at line 1787 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__ispec_toregconst_raw(), duk__ivalue_toplain_raw(), and duk__ivalue_toregconst_raw().
#define DUK__IVAL_FLAG_REQUIRE_TEMP (1 << 1) /* require a (mutable) temporary as a result (or a const if allowed) */ |
Definition at line 1786 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__expr_nud(), duk__ispec_toregconst_raw(), duk__ivalue_toregconst_raw(), and duk__ivalue_totempconst().
#define DUK__MAX_ARRAY_INIT_VALUES 20 |
Definition at line 35 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__nud_array_literal().
#define DUK__MAX_CONSTS DUK_BC_BC_MAX |
Definition at line 44 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__getconst().
#define DUK__MAX_FUNCS DUK_BC_BC_MAX |
Definition at line 45 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_func_like_fnum().
#define DUK__MAX_OBJECT_INIT_PAIRS 10 |
Definition at line 36 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__nud_object_literal().
#define DUK__MAX_TEMPS 0xffffL |
Definition at line 46 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__alloctemps().
#define DUK__MK_LBP | ( | bp | ) | ((bp) >> 1) /* bp is assumed to be even */ |
Definition at line 270 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__MK_LBP_FLAGS | ( | bp, | |
flags ) (((bp) >> 1) | (flags)) |
Definition at line 271 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__OBJ_LIT_KEY_GET (1 << 1) /* key encountered as a getter */ |
Definition at line 2737 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__nud_object_literal(), and duk__nud_object_literal_key_check().
#define DUK__OBJ_LIT_KEY_PLAIN (1 << 0) /* key encountered as a plain property */ |
Definition at line 2736 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__nud_object_literal(), and duk__nud_object_literal_key_check().
#define DUK__OBJ_LIT_KEY_SET (1 << 2) /* key encountered as a setter */ |
Definition at line 2738 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__nud_object_literal(), and duk__nud_object_literal_key_check().
#define DUK__PARSE_EXPR_SLOTS 16 |
Definition at line 68 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr().
#define DUK__PARSE_STATEMENTS_SLOTS 16 |
Definition at line 67 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmts().
#define DUK__RECURSION_DECREASE | ( | comp_ctx, | |
thr ) |
Definition at line 56 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr(), duk__parse_func_body(), and duk__parse_stmt().
#define DUK__RECURSION_INCREASE | ( | comp_ctx, | |
thr ) |
Definition at line 51 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr(), duk__parse_func_body(), and duk__parse_stmt().
#define DUK__SETTEMP | ( | comp_ctx, | |
x ) ((comp_ctx)->curr_func.temp_next = (x)) /* dangerous: must only lower (temp_max not updated) */ |
Definition at line 1776 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_led(), duk__expr_nud(), duk__init_varmap_and_prologue_for_pass2(), duk__ivalue_toplain_ignore(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_arguments(), duk__parse_for_stmt(), duk__parse_if_stmt(), duk__parse_stmt(), duk__parse_switch_stmt(), and duk__parse_while_stmt().
#define DUK__SETTEMP_CHECKMAX | ( | comp_ctx, | |
x ) duk__settemp_checkmax((comp_ctx),(x)) |
Definition at line 1777 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__init_varmap_and_prologue_for_pass2().
#define DUK__STILL_PROLOGUE (1 << 3) /* statement does not terminate directive prologue */ |
Definition at line 4955 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__parse_stmt().
#define DUK__TOKEN_LBP_BP_MASK 0x1f |
Definition at line 263 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__TOKEN_LBP_FLAG_NO_REGEXP (1 << 5) /* regexp literal must not follow this token */ |
Definition at line 264 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__advance_helper().
#define DUK__TOKEN_LBP_FLAG_TERMINATES (1 << 6) /* terminates expression; e.g. post-increment/-decrement */ |
Definition at line 265 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__TOKEN_LBP_FLAG_UNUSED (1 << 7) /* spare */ |
Definition at line 266 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
#define DUK__TOKEN_LBP_GET_BP | ( | x | ) | ((duk_small_uint_t) (((x) & DUK__TOKEN_LBP_BP_MASK) * 2)) |
Definition at line 268 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__expr_lbp().
DUK_LOCAL_DECL void duk__add_label | ( | duk_compiler_ctx * | comp_ctx, |
duk_hstring * | h_label, | ||
duk_int_t | pc_label, | ||
duk_int_t | label_id ) |
Definition at line 2537 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_labelinfo::catch_depth, duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, DUK_HBUFFER_DYNAMIC_GET_DATA_PTR, DUK_HBUFFER_GET_SIZE, duk_hbuffer_resize(), DUK_HTHREAD_STRING_EMPTY_STRING, DUK_LABEL_FLAG_ALLOW_BREAK, duk_push_hstring(), duk_put_prop_index(), DUK_STR_DUPLICATE_LABEL, DUK_UARRIDX_MAX, DUK_UNREF, duk_labelinfo::flags, duk_labelinfo::h_label, duk_compiler_func::h_labelinfos, duk_hthread::heap, duk_labelinfo::label_id, duk_compiler_func::labelnames_idx, duk_labelinfo::pc_label, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__advance | ( | duk_compiler_ctx * | ctx | ) |
Definition at line 479 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__advance_helper().
Referenced by duk__expr(), duk__expr_led(), duk__expr_nud(), duk__js_compile_raw(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_break_or_continue_stmt(), duk__parse_do_stmt(), duk__parse_for_stmt(), duk__parse_func_body(), duk__parse_func_formals(), duk__parse_func_like_fnum(), duk__parse_func_like_raw(), duk__parse_if_stmt(), duk__parse_return_stmt(), duk__parse_stmt(), duk__parse_stmts(), duk__parse_switch_stmt(), duk__parse_throw_stmt(), duk__parse_try_stmt(), duk__parse_var_decl(), duk__parse_var_stmt(), duk__parse_while_stmt(), and duk__parse_with_stmt().
DUK_LOCAL_DECL void duk__advance_expect | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_int_t | expect ) |
Definition at line 474 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__advance_helper().
Referenced by duk__expr_led(), duk__expr_nud(), duk__js_compile_raw(), duk__nud_object_literal(), duk__parse_arguments(), duk__parse_do_stmt(), duk__parse_for_stmt(), duk__parse_func_body(), duk__parse_func_formals(), duk__parse_func_like_fnum(), duk__parse_func_like_raw(), duk__parse_if_stmt(), duk__parse_switch_stmt(), duk__parse_try_stmt(), duk__parse_while_stmt(), and duk__parse_with_stmt().
DUK_LOCAL_DECL void duk__advance_helper | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_int_t | expect ) |
Definition at line 415 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__token_lbp, DUK__TOKEN_LBP_FLAG_NO_REGEXP, DUK_ASSERT, duk_copy(), DUK_D, DUK_DDD, DUK_DDDPRINT, DUK_DPRINT, DUK_ERROR_SYNTAX, duk_get_tval(), duk_lexer_parse_js_input_element(), DUK_MEMCPY, DUK_STR_PARSE_ERROR, DUK_TOK_MAXVAL, duk_compiler_func::is_strict, duk_compiler_ctx::lex, duk_token::lineterm, duk_compiler_ctx::prev_token, duk_compiler_func::reject_regexp_in_adv, duk_token::start_line, duk_token::t, duk_token::t_nores, duk_compiler_ctx::thr, duk_compiler_ctx::tok11_idx, duk_compiler_ctx::tok12_idx, duk_compiler_ctx::tok21_idx, and duk_compiler_ctx::tok22_idx.
Referenced by duk__advance(), and duk__advance_expect().
DUK_LOCAL_DECL duk_reg_t duk__alloctemp | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1874 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__alloctemps().
DUK_LOCAL_DECL duk_reg_t duk__alloctemps | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_int_t | num ) |
Definition at line 1856 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK__MAX_TEMPS, DUK_ERROR_RANGE, DUK_STR_TEMP_LIMIT, duk_compiler_func::temp_max, duk_compiler_func::temp_next, and duk_compiler_ctx::thr.
Referenced by duk__alloctemp().
DUK_LOCAL_DECL duk_int_t duk__cleanup_varmap | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 580 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK_ASSERT, duk_compact(), DUK_GET_HOBJECT_NEGIDX, DUK_HOBJECT_E_GET_KEY, DUK_HOBJECT_E_GET_VALUE_TVAL_PTR, DUK_HOBJECT_E_SET_KEY, DUK_HOBJECT_E_SLOT_IS_ACCESSOR, DUK_HOBJECT_GET_ENEXT, DUK_HSTRING_DECREF, DUK_TVAL_IS_HEAP_ALLOCATED, DUK_TVAL_IS_NUMBER, duk_hthread::heap, NULL, and duk_compiler_ctx::thr.
Referenced by duk__convert_to_func_template().
DUK_LOCAL_DECL void duk__convert_to_func_template | ( | duk_compiler_ctx * | comp_ctx, |
duk_bool_t | force_no_namebind ) |
Definition at line 631 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::argnames_idx, duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, duk__cleanup_varmap(), DUK_ASSERT, DUK_BW_GET_BASEPTR, DUK_BW_GET_SIZE, duk_compact(), DUK_COMPILER_MAX_BYTECODE_LENGTH, DUK_DD, DUK_DDD, DUK_DDDPRINT, DUK_DDPRINT, DUK_DEC_A, DUK_DEC_B, DUK_DEC_C, DUK_DEC_OP, duk_dup(), duk_get_hbuffer(), duk_get_hobject(), DUK_GET_HOBJECT_NEGIDX, duk_get_tval(), DUK_HBUFFER_FIXED_GET_DATA_PTR, DUK_HCOMPILEDFUNCTION_GET_CODE_BASE, DUK_HCOMPILEDFUNCTION_GET_CODE_END, DUK_HCOMPILEDFUNCTION_SET_BYTECODE, DUK_HCOMPILEDFUNCTION_SET_DATA, DUK_HCOMPILEDFUNCTION_SET_FUNCS, DUK_HEAPHDR_INCREF, duk_hobject_find_existing_array_entry_tval_ptr(), duk_hobject_get_length(), DUK_HOBJECT_HAS_NEWENV, DUK_HOBJECT_INCREF, DUK_HOBJECT_IS_COMPILEDFUNCTION, duk_hobject_pc2line_pack(), DUK_HOBJECT_SET_CREATEARGS, DUK_HOBJECT_SET_NAMEBINDING, DUK_HOBJECT_SET_NEWENV, DUK_HOBJECT_SET_NOTAIL, DUK_HOBJECT_SET_STRICT, duk_pop(), DUK_PROPDESC_FLAGS_NONE, duk_push_compiledfunction(), duk_push_fixed_buffer, duk_push_hstring(), duk_push_string(), DUK_STRIDX_FILE_NAME, DUK_STRIDX_INT_FORMALS, DUK_STRIDX_INT_PC2LINE, DUK_STRIDX_INT_SOURCE, DUK_STRIDX_INT_VARMAP, DUK_STRIDX_NAME, DUK_TVAL_GET_OBJECT, DUK_TVAL_INCREF, DUK_TVAL_IS_OBJECT, DUK_TVAL_SET_TVAL, DUK_UARRIDX_MAX, duk_xdef_prop_stridx(), duk_compiler_func::h_argnames, duk_compiler_func::h_consts, duk_compiler_ctx::h_filename, duk_compiler_func::h_funcs, duk_compiler_func::h_name, duk_hthread::heap, duk_compiler_func::id_access_arguments, duk_compiler_func::id_access_slow, duk_compiler_instr::ins, duk_compiler_func::is_arguments_shadowed, duk_compiler_func::is_decl, duk_compiler_func::is_eval, duk_compiler_func::is_function, duk_compiler_func::is_notail, duk_compiler_func::is_strict, duk_compiler_func::may_direct_eval, duk_hcompiledfunction::nargs, duk_hcompiledfunction::nregs, NULL, duk_compiler_func::temp_max, duk_compiler_ctx::thr, and duk_compiler_func::varmap_idx.
Referenced by duk__js_compile_raw(), and duk__parse_func_like_raw().
DUK_LOCAL_DECL void duk__copy_ispec | ( | duk_compiler_ctx * | comp_ctx, |
duk_ispec * | src, | ||
duk_ispec * | dst ) |
Definition at line 1815 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_copy(), duk_ispec::regconst, duk_ispec::t, duk_compiler_ctx::thr, and duk_ispec::valstack_idx.
Referenced by duk__expr_led().
DUK_LOCAL_DECL void duk__copy_ivalue | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | src, | ||
duk_ivalue * | dst ) |
Definition at line 1823 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_copy(), duk_ivalue::op, duk_ispec::regconst, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__expr(), and duk__expr_led().
DUK_LOCAL_DECL void duk__emit | ( | duk_compiler_ctx * | comp_ctx, |
duk_instr_t | ins ) |
Definition at line 1032 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, curr_func, duk_compiler_ctx::curr_token, duk__get_current_pc(), DUK_BW_ADD_PTR, DUK_BW_ENSURE_GETPTR, DUK_BW_GET_SIZE, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_RANGE, DUK_STR_BYTECODE_LIMIT, DUK_UNLIKELY, DUK_USE_ESBC_MAX_BYTES, DUK_USE_ESBC_MAX_LINENUMBER, duk_compiler_instr::ins, duk_compiler_instr::line, duk_compiler_ctx::prev_token, duk_token::start_line, and duk_compiler_ctx::thr.
Referenced by duk__emit_a_b_c(), duk__emit_a_bc(), and duk__emit_abc().
DUK_LOCAL_DECL void duk__emit_a_b | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | op_flags, | ||
duk_regconst_t | a, | ||
duk_regconst_t | b ) |
Definition at line 1379 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_b_c(), and DUK__EMIT_FLAG_NO_SHUFFLE_C.
Referenced by duk__expr_led(), duk__expr_nud(), duk__parse_func_body(), and duk__parse_return_stmt().
DUK_LOCAL_DECL void duk__emit_a_b_c | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | op_flags, | ||
duk_regconst_t | a, | ||
duk_regconst_t | b, | ||
duk_regconst_t | c ) |
Definition at line 1131 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK__CONST_MARKER, duk__emit(), duk__emit_abc(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EMIT_FLAG_B_IS_TARGET, DUK__EMIT_FLAG_B_IS_TARGETSOURCE, DUK__EMIT_FLAG_C_IS_TARGET, DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__EMIT_FLAG_NO_SHUFFLE_B, DUK__EMIT_FLAG_NO_SHUFFLE_C, DUK__EMIT_FLAG_RESERVE_JUMPSLOT, duk__emit_load_int32_noshuffle(), duk__get_current_pc(), DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_A_MAX, DUK_BC_A_MIN, DUK_BC_B_MAX, DUK_BC_B_MIN, DUK_BC_BC_MAX, DUK_BC_C_MAX, DUK_BC_C_MIN, DUK_BC_OP_MAX, DUK_BC_OP_MIN, DUK_D, DUK_DDD, DUK_DDDPRINT, DUK_DPRINT, DUK_ENC_OP_A_B_C, DUK_ENC_OP_A_BC, DUK_ERROR_RANGE, DUK_EXTRAOP_INITGET, DUK_EXTRAOP_INITGETI, DUK_EXTRAOP_INITSET, DUK_EXTRAOP_INITSETI, DUK_OP_CALL, DUK_OP_CALLI, DUK_OP_CSPROP, DUK_OP_CSPROPI, DUK_OP_CSREG, DUK_OP_CSREGI, DUK_OP_CSVAR, DUK_OP_CSVARI, DUK_OP_EXTRA, DUK_OP_JUMP, DUK_OP_LDCONST, DUK_OP_LDREG, DUK_OP_MPUTARR, DUK_OP_MPUTARRI, DUK_OP_MPUTOBJ, DUK_OP_MPUTOBJI, DUK_OP_NEW, DUK_OP_NEWI, DUK_OP_STREG, DUK_STR_REG_LIMIT, duk_compiler_ctx::emit_jumpslot_pc, duk_compiler_func::needs_shuffle, duk_compiler_func::shuffle1, duk_compiler_func::shuffle2, duk_compiler_func::shuffle3, and duk_compiler_ctx::thr.
Referenced by duk__emit_a_b(), duk__emit_extraop_b(), duk__emit_extraop_b_c(), duk__emit_extraop_only(), duk__emit_if_false_skip(), duk__emit_if_true_skip(), duk__expr_led(), duk__expr_nud(), duk__init_varmap_and_prologue_for_pass2(), duk__ivalue_toplain_raw(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_for_stmt(), and duk__parse_switch_stmt().
DUK_LOCAL_DECL void duk__emit_a_bc | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | op_flags, | ||
duk_regconst_t | a, | ||
duk_regconst_t | bc ) |
Definition at line 1389 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK__CONST_MARKER, duk__emit(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_A_MAX, DUK_BC_BC_MAX, DUK_BC_BC_MIN, DUK_BC_OP_MAX, DUK_BC_OP_MIN, DUK_ENC_OP_A_BC, DUK_ERROR_RANGE, DUK_OP_LDREG, DUK_OP_STREG, DUK_STR_REG_LIMIT, duk_compiler_func::needs_shuffle, duk_compiler_func::shuffle1, and duk_compiler_ctx::thr.
Referenced by duk__emit_extraop_bc(), duk__emit_load_int32_raw(), duk__expr_led(), duk__expr_nud(), duk__init_varmap_and_prologue_for_pass2(), duk__ispec_toregconst_raw(), duk__ivalue_toplain_raw(), duk__nud_object_literal(), duk__parse_for_stmt(), duk__parse_try_stmt(), duk__parse_var_decl(), and duk__parse_with_stmt().
DUK_LOCAL_DECL void duk__emit_abc | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | op, | ||
duk_regconst_t | abc ) |
Definition at line 1438 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, DUK__CONST_MARKER, duk__emit(), duk__get_current_pc(), DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_ABC_MAX, DUK_BC_ABC_MIN, DUK_BC_OP_MAX, DUK_BC_OP_MIN, DUK_DDD, DUK_DDDPRINT, DUK_ENC_OP_ABC, DUK_ERROR_RANGE, DUK_STR_REG_LIMIT, duk_token::start_line, and duk_compiler_ctx::thr.
Referenced by duk__emit_a_b_c(), duk__emit_jump(), and duk__emit_jump_empty().
DUK_LOCAL_DECL void duk__emit_extraop_b | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | extraop_flags, | ||
duk_regconst_t | b ) |
Definition at line 1477 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_b_c(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_EXTRAOP_MAX, DUK_BC_EXTRAOP_MIN, and DUK_OP_EXTRA.
Referenced by duk__parse_try_stmt().
DUK_LOCAL_DECL void duk__emit_extraop_b_c | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | extraop_flags, | ||
duk_regconst_t | b, | ||
duk_regconst_t | c ) |
Definition at line 1464 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_b_c(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_EXTRAOP_MAX, DUK_BC_EXTRAOP_MIN, and DUK_OP_EXTRA.
Referenced by duk__expr_nud(), duk__ivalue_toplain_raw(), duk__nud_array_literal(), duk__nud_object_literal(), and duk__parse_for_stmt().
DUK_LOCAL_DECL void duk__emit_extraop_bc | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | extraop, | ||
duk_regconst_t | bc ) |
Definition at line 1490 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_bc(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_EXTRAOP_MAX, DUK_BC_EXTRAOP_MIN, and DUK_OP_EXTRA.
Referenced by duk__emit_invalid(), duk__expr_led(), duk__expr_nud(), duk__ispec_toregconst_raw(), duk__parse_break_or_continue_stmt(), duk__parse_func_body(), duk__parse_stmt(), duk__parse_throw_stmt(), and duk__stmt_label_site().
DUK_LOCAL_DECL void duk__emit_extraop_only | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | extraop_flags ) |
Definition at line 1502 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_b_c(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__EMIT_FLAG_NO_SHUFFLE_B, DUK__EMIT_FLAG_NO_SHUFFLE_C, DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_EXTRAOP_MAX, DUK_BC_EXTRAOP_MIN, and DUK_OP_EXTRA.
Referenced by duk__expr_led(), duk__expr_nud(), duk__parse_for_stmt(), duk__parse_stmt(), duk__parse_try_stmt(), and duk__parse_with_stmt().
DUK_LOCAL_DECL void duk__emit_if_false_skip | ( | duk_compiler_ctx * | comp_ctx, |
duk_regconst_t | regconst ) |
Definition at line 1681 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_b_c(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__EMIT_FLAG_NO_SHUFFLE_C, and DUK_OP_IF.
Referenced by duk__parse_do_stmt(), and duk__parse_for_stmt().
DUK_LOCAL_DECL void duk__emit_if_true_skip | ( | duk_compiler_ctx * | comp_ctx, |
duk_regconst_t | regconst ) |
Definition at line 1689 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_b_c(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__EMIT_FLAG_NO_SHUFFLE_C, and DUK_OP_IF.
Referenced by duk__expr_led(), duk__parse_if_stmt(), duk__parse_switch_stmt(), and duk__parse_while_stmt().
DUK_LOCAL_DECL void duk__emit_invalid | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1697 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_extraop_bc(), and DUK_EXTRAOP_INVALID.
Referenced by duk__parse_try_stmt(), duk__parse_with_stmt(), and duk__stmt_label_site().
DUK_LOCAL_DECL void duk__emit_jump | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | target_pc ) |
Definition at line 1558 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, duk__emit_abc(), DUK_ASSERT, DUK_BC_ABC_MAX, DUK_BC_ABC_MIN, DUK_BC_JUMP_BIAS, DUK_BW_GET_SIZE, DUK_OP_JUMP, and duk_compiler_ctx::thr.
Referenced by duk__parse_break_or_continue_stmt(), duk__parse_do_stmt(), duk__parse_for_stmt(), and duk__parse_while_stmt().
DUK_LOCAL_DECL duk_int_t duk__emit_jump_empty | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1569 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_abc(), duk__get_current_pc(), and DUK_OP_JUMP.
Referenced by duk__expr_led(), duk__parse_for_stmt(), duk__parse_if_stmt(), duk__parse_switch_stmt(), and duk__parse_while_stmt().
DUK_LOCAL_DECL void duk__emit_load_int32 | ( | duk_compiler_ctx * | comp_ctx, |
duk_reg_t | reg, | ||
duk_int32_t | val ) |
Definition at line 1537 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_load_int32_raw().
Referenced by duk__emit_load_int32_noshuffle(), duk__ispec_toregconst_raw(), and duk__nud_array_literal().
DUK_LOCAL_DECL void duk__emit_load_int32_noshuffle | ( | duk_compiler_ctx * | comp_ctx, |
duk_reg_t | reg, | ||
duk_int32_t | val ) |
Definition at line 1549 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_load_int32(), DUK_ASSERT, and DUK_BC_A_MAX.
Referenced by duk__emit_a_b_c().
DUK_LOCAL void duk__emit_load_int32_raw | ( | duk_compiler_ctx * | comp_ctx, |
duk_reg_t | reg, | ||
duk_int32_t | val, | ||
duk_small_uint_t | op_flags ) |
Definition at line 1516 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__emit_a_bc(), DUK_ASSERT, DUK_BC_BC_MAX, DUK_BC_BC_MIN, DUK_BC_LDINT_BIAS, DUK_BC_LDINTX_SHIFT, DUK_DDD, DUK_DDDPRINT, DUK_OP_LDINT, and DUK_OP_LDINTX.
Referenced by duk__emit_load_int32().
DUK_LOCAL_DECL void duk__expr | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4765 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::allow_in, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__copy_ivalue(), DUK__EXPR_FLAG_ALLOW_EMPTY, duk__expr_lbp(), duk__expr_led(), duk__expr_nud(), DUK__EXPR_RBP_MASK, DUK__PARSE_EXPR_SLOTS, DUK__RECURSION_DECREASE, DUK__RECURSION_INCREASE, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, duk_get_top(), DUK_ISPEC_VALUE, DUK_IVAL_PLAIN, DUK_MEMZERO, duk_pop_2(), duk_push_undefined(), duk_replace(), duk_require_stack(), DUK_STR_EMPTY_EXPR_NOT_ALLOWED, DUK_TOK_RPAREN, DUK_TOK_SEMICOLON, duk_compiler_func::paren_level, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__expr_led(), duk__expr_nud(), duk__expr_toforcedreg(), duk__expr_toplain(), duk__expr_toplain_ignore(), duk__expr_toregconst(), and duk__exprtop().
DUK_LOCAL_DECL duk_bool_t duk__expr_is_empty | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 3238 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_compiler_func::led_count, and duk_compiler_func::nud_count.
Referenced by duk__exprtop(), and duk__parse_for_stmt().
DUK_LOCAL_DECL duk_small_uint_t duk__expr_lbp | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 4721 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::allow_in, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__token_lbp, DUK__TOKEN_LBP_GET_BP, DUK_ASSERT, DUK_TOK_DECREMENT, DUK_TOK_IN, DUK_TOK_INCREMENT, DUK_TOK_MAXVAL, DUK_TOK_MINVAL, duk_token::lineterm, and duk_token::t.
Referenced by duk__expr().
DUK_LOCAL_DECL void duk__expr_led | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | left, | ||
duk_ivalue * | res ) |
Definition at line 3768 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::allow_in, duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMP, DUK__ALLOCTEMPS, DUK__BP_ADDITIVE, DUK__BP_ASSIGNMENT, DUK__BP_BAND, DUK__BP_BOR, DUK__BP_BXOR, DUK__BP_COMMA, DUK__BP_EQUALITY, DUK__BP_FOR_EXPR, DUK__BP_LAND, DUK__BP_LOR, DUK__BP_MULTIPLICATIVE, DUK__BP_RELATIONAL, DUK__BP_SHIFT, DUK__CONST_MARKER, duk__copy_ispec(), duk__copy_ivalue(), duk__emit_a_b(), duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_extraop_bc(), duk__emit_extraop_only(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__EMIT_FLAG_NO_SHUFFLE_C, duk__emit_if_true_skip(), duk__emit_jump_empty(), duk__expr(), duk__expr_toforcedreg(), duk__expr_toplain(), duk__expr_toregconst(), duk__get_current_pc(), duk__hstring_is_eval_or_arguments_in_strict_mode(), duk__ispec_toforcedreg(), duk__ispec_toregconst_raw(), DUK__ISTEMP, DUK__IVAL_FLAG_ALLOW_CONST, DUK__IVAL_FLAG_REQUIRE_TEMP, duk__ivalue_toforcedreg(), duk__ivalue_toplain(), duk__ivalue_toplain_ignore(), duk__ivalue_toreg(), duk__ivalue_totempconst(), duk__lookup_lhs(), duk__parse_arguments(), duk__patch_jump_here(), DUK__SETTEMP, DUK_ASSERT, DUK_BC_CALL_FLAG_EVALCALL, DUK_BW_ADD_PTR, duk_copy(), DUK_D, DUK_DD, DUK_DDD, DUK_DDDPRINT, DUK_DDPRINT, DUK_DPRINT, duk_dup(), DUK_ERROR_SYNTAX, DUK_EXTRAOP_IN, DUK_EXTRAOP_INSTOF, DUK_EXTRAOP_INVLHS, DUK_EXTRAOP_UNP, duk_get_hstring(), DUK_HTHREAD_STRING_EVAL, DUK_ISPEC_REGCONST, DUK_ISPEC_VALUE, DUK_IVAL_ARITH, DUK_IVAL_ARITH_EXTRAOP, DUK_IVAL_PLAIN, DUK_IVAL_PROP, DUK_IVAL_VAR, DUK_OP_ADD, DUK_OP_BAND, DUK_OP_BASL, DUK_OP_BASR, DUK_OP_BLSR, DUK_OP_BOR, DUK_OP_BXOR, DUK_OP_CALL, DUK_OP_CSPROP, DUK_OP_CSREG, DUK_OP_CSVAR, DUK_OP_DIV, DUK_OP_EQ, DUK_OP_GE, DUK_OP_GETPROP, DUK_OP_GETVAR, DUK_OP_GT, DUK_OP_IF, DUK_OP_LDREG, DUK_OP_LE, DUK_OP_LT, DUK_OP_MOD, DUK_OP_MUL, DUK_OP_NEQ, DUK_OP_NONE, DUK_OP_POSTDECP, DUK_OP_POSTDECR, DUK_OP_POSTDECV, DUK_OP_POSTINCP, DUK_OP_POSTINCR, DUK_OP_POSTINCV, DUK_OP_PUTPROP, DUK_OP_PUTVAR, DUK_OP_SEQ, DUK_OP_SNEQ, DUK_OP_SUB, duk_push_hstring(), duk_replace(), DUK_STR_EXPECTED_IDENTIFIER, DUK_STR_INVALID_EXPRESSION, DUK_STR_INVALID_LVALUE, DUK_STR_PARSE_ERROR, DUK_TOK_ADD, DUK_TOK_ADD_EQ, DUK_TOK_ALSHIFT, DUK_TOK_ALSHIFT_EQ, DUK_TOK_ARSHIFT, DUK_TOK_ARSHIFT_EQ, DUK_TOK_BAND, DUK_TOK_BAND_EQ, DUK_TOK_BOR, DUK_TOK_BOR_EQ, DUK_TOK_BXOR, DUK_TOK_BXOR_EQ, DUK_TOK_COLON, DUK_TOK_COMMA, DUK_TOK_DECREMENT, DUK_TOK_DIV, DUK_TOK_DIV_EQ, DUK_TOK_EQ, DUK_TOK_EQUALSIGN, DUK_TOK_GE, DUK_TOK_GT, DUK_TOK_IDENTIFIER, DUK_TOK_IN, DUK_TOK_INCREMENT, DUK_TOK_INSTANCEOF, DUK_TOK_LAND, DUK_TOK_LBRACKET, DUK_TOK_LE, DUK_TOK_LOR, DUK_TOK_LPAREN, DUK_TOK_LT, DUK_TOK_MOD, DUK_TOK_MOD_EQ, DUK_TOK_MUL, DUK_TOK_MUL_EQ, DUK_TOK_NEQ, DUK_TOK_PERIOD, DUK_TOK_QUESTION, DUK_TOK_RBRACKET, DUK_TOK_RSHIFT, DUK_TOK_RSHIFT_EQ, DUK_TOK_SEQ, DUK_TOK_SNEQ, DUK_TOK_SUB, DUK_TOK_SUB_EQ, duk_compiler_func::led_count, left, duk_compiler_func::may_direct_eval, duk_compiler_func::nud_count, NULL, duk_ivalue::op, duk_compiler_func::paren_level, duk_compiler_ctx::prev_token, duk_ispec::regconst, duk_compiler_func::reject_regexp_in_adv, duk_token::str1, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_token::t_nores, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__expr().
DUK_LOCAL_DECL void duk__expr_nud | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 3244 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::allow_in, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk_double_union::d, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMP, DUK__BP_CALL, DUK__BP_FOR_EXPR, DUK__BP_MULTIPLICATIVE, duk__emit_a_b(), duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_extraop_b_c(), duk__emit_extraop_bc(), duk__emit_extraop_only(), DUK__EMIT_FLAG_B_IS_TARGET, DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__EMIT_FLAG_NO_SHUFFLE_C, duk__expr(), duk__expr_toforcedreg(), duk__expr_toplain_ignore(), duk__getconst(), DUK__GETTEMP, duk__hstring_is_eval_or_arguments_in_strict_mode(), duk__ispec_toregconst_raw(), DUK__IVAL_FLAG_ALLOW_CONST, DUK__IVAL_FLAG_REQUIRE_TEMP, duk__ivalue_toforcedreg(), duk__ivalue_toregconst_raw(), duk__lookup_lhs(), duk__nud_array_literal(), duk__nud_object_literal(), duk__parse_arguments(), duk__parse_func_like_fnum(), DUK__SETTEMP, DUK_ASSERT, DUK_DBLUNION_NORMALIZE_NAN_CHECK, DUK_DDD, DUK_DDDPRINT, duk_dup(), DUK_ERROR_SYNTAX, DUK_EXTRAOP_BNOT, DUK_EXTRAOP_INVLHS, DUK_EXTRAOP_LDFALSE, DUK_EXTRAOP_LDTHIS, DUK_EXTRAOP_LNOT, DUK_EXTRAOP_TYPEOF, DUK_EXTRAOP_TYPEOFID, DUK_EXTRAOP_UNM, DUK_EXTRAOP_UNP, duk_get_hstring(), DUK_GET_TVAL_POSIDX, duk_is_number(), DUK_ISPEC_REGCONST, DUK_ISPEC_VALUE, DUK_IVAL_NONE, DUK_IVAL_PLAIN, DUK_IVAL_PROP, DUK_IVAL_VAR, DUK_OP_CLOSURE, DUK_OP_DELPROP, DUK_OP_DELVAR, DUK_OP_NEW, DUK_OP_PREDECP, DUK_OP_PREDECR, DUK_OP_PREDECV, DUK_OP_PREINCP, DUK_OP_PREINCR, DUK_OP_PREINCV, DUK_OP_REGEXP, duk_push_false(), duk_push_hstring(), duk_push_null(), duk_push_number(), duk_push_true(), duk_push_undefined(), duk_regexp_compile(), duk_replace(), DUK_STR_CANNOT_DELETE_IDENTIFIER, DUK_STR_INVALID_EXPRESSION, DUK_STR_PARSE_ERROR, DUK_TOK_ADD, DUK_TOK_BNOT, DUK_TOK_DECREMENT, DUK_TOK_DELETE, DUK_TOK_FALSE, DUK_TOK_FUNCTION, DUK_TOK_IDENTIFIER, DUK_TOK_INCREMENT, DUK_TOK_LBRACKET, DUK_TOK_LCURLY, DUK_TOK_LNOT, DUK_TOK_LPAREN, DUK_TOK_NEW, DUK_TOK_NULL, DUK_TOK_NUMBER, DUK_TOK_REGEXP, DUK_TOK_RPAREN, DUK_TOK_STRING, DUK_TOK_SUB, DUK_TOK_THIS, DUK_TOK_TRUE, DUK_TOK_TYPEOF, DUK_TOK_VOID, DUK_TVAL_GET_BOOLEAN, DUK_TVAL_GET_NUMBER, DUK_TVAL_IS_BOOLEAN, DUK_TVAL_IS_NUMBER, DUK_TVAL_SET_BOOLEAN, DUK_TVAL_SET_BOOLEAN_FALSE, DUK_TVAL_SET_BOOLEAN_TRUE, DUK_TVAL_SET_NUMBER, duk_compiler_func::is_strict, duk_compiler_func::nud_count, NULL, duk_token::num, duk_compiler_func::paren_level, duk_compiler_ctx::prev_token, duk_ispec::regconst, duk_token::str1, duk_token::str2, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__expr().
DUK_LOCAL_DECL void duk__expr_toforcedreg | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags, | ||
duk_reg_t | forced_reg ) |
Definition at line 4866 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__expr(), duk__ivalue_toforcedreg(), and DUK_ASSERT.
Referenced by duk__expr_led(), duk__expr_nud(), duk__nud_array_literal(), duk__nud_object_literal(), and duk__parse_arguments().
DUK_LOCAL_DECL void duk__expr_toplain | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4884 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__expr(), and duk__ivalue_toplain().
Referenced by duk__expr_led().
DUK_LOCAL_DECL void duk__expr_toplain_ignore | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4889 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__expr(), and duk__ivalue_toplain_ignore().
Referenced by duk__expr_nud().
DUK_LOCAL_DECL duk_regconst_t duk__expr_toregconst | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4872 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__expr(), and duk__ivalue_toregconst().
Referenced by duk__expr_led().
DUK_LOCAL_DECL void duk__exprtop | ( | duk_compiler_ctx * | ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4827 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::allow_in, duk_compiler_ctx::curr_func, duk__expr(), DUK__EXPR_FLAG_ALLOW_EMPTY, DUK__EXPR_FLAG_REJECT_IN, duk__expr_is_empty(), DUK_ERROR_SYNTAX, DUK_STR_EMPTY_EXPR_NOT_ALLOWED, duk_compiler_func::expr_lhs, duk_compiler_func::led_count, duk_compiler_func::nud_count, duk_compiler_func::paren_level, and duk_compiler_ctx::thr.
Referenced by duk__exprtop_toforcedreg(), duk__exprtop_toreg(), duk__exprtop_toregconst(), duk__parse_for_stmt(), duk__parse_stmt(), and duk__parse_var_decl().
DUK_LOCAL_DECL void duk__exprtop_toforcedreg | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags, | ||
duk_reg_t | forced_reg ) |
Definition at line 4906 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__exprtop(), duk__ivalue_toforcedreg(), and DUK_ASSERT.
Referenced by duk__parse_with_stmt().
DUK_LOCAL_DECL duk_reg_t duk__exprtop_toreg | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4894 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__exprtop(), and duk__ivalue_toreg().
Referenced by duk__parse_for_stmt(), and duk__parse_throw_stmt().
DUK_LOCAL_DECL duk_regconst_t duk__exprtop_toregconst | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | rbp_flags ) |
Definition at line 4912 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__exprtop(), and duk__ivalue_toregconst().
Referenced by duk__parse_do_stmt(), duk__parse_if_stmt(), duk__parse_return_stmt(), duk__parse_switch_stmt(), and duk__parse_while_stmt().
DUK_LOCAL_DECL duk_int_t duk__get_current_pc | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1017 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, DUK_BW_GET_SIZE, and duk_compiler_ctx::thr.
Referenced by duk__emit(), duk__emit_a_b_c(), duk__emit_abc(), duk__emit_jump_empty(), duk__expr_led(), duk__parse_do_stmt(), duk__parse_for_stmt(), duk__parse_return_stmt(), duk__parse_stmt(), duk__parse_switch_stmt(), duk__parse_try_stmt(), duk__parse_while_stmt(), duk__parse_with_stmt(), and duk__patch_jump_here().
DUK_LOCAL_DECL duk_compiler_instr * duk__get_instr_ptr | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | pc ) |
Definition at line 1023 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_BW_GET_BASEPTR, DUK_BW_GET_SIZE, and duk_compiler_ctx::thr.
Referenced by duk__parse_return_stmt(), duk__patch_jump(), and duk__patch_trycatch().
DUK_LOCAL_DECL duk_regconst_t duk__getconst | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1886 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::consts_idx, duk_compiler_ctx::curr_func, DUK__CONST_MARKER, DUK__GETCONST_MAX_CONSTS_CHECK, DUK__MAX_CONSTS, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_RANGE, duk_get_length(), DUK_GET_TVAL_NEGIDX, DUK_HOBJECT_A_GET_VALUE_PTR, duk_js_samevalue, duk_pop(), duk_put_prop_index(), DUK_STR_CONST_LIMIT, DUK_TVAL_CHKFAST_INPLACE, duk_compiler_func::h_consts, duk_hthread::heap, NULL, and duk_compiler_ctx::thr.
Referenced by duk__expr_nud(), duk__init_varmap_and_prologue_for_pass2(), duk__ispec_toregconst_raw(), duk__lookup_lhs(), duk__nud_object_literal(), and duk__parse_try_stmt().
DUK_LOCAL duk_bool_t duk__hstring_is_eval_or_arguments | ( | duk_compiler_ctx * | comp_ctx, |
duk_hstring * | h ) |
Definition at line 395 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK_ASSERT, DUK_HSTRING_HAS_EVAL_OR_ARGUMENTS, DUK_UNREF, and NULL.
Referenced by duk__init_varmap_and_prologue_for_pass2(), and duk__parse_func_body().
DUK_LOCAL duk_bool_t duk__hstring_is_eval_or_arguments_in_strict_mode | ( | duk_compiler_ctx * | comp_ctx, |
duk_hstring * | h ) |
Definition at line 401 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_HSTRING_HAS_EVAL_OR_ARGUMENTS, duk_compiler_func::is_strict, and NULL.
Referenced by duk__expr_led(), duk__expr_nud(), and duk__parse_var_decl().
DUK_LOCAL_DECL void duk__init_func_valstack_slots | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 488 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::argnames_idx, duk_compiler_func::bw_code, duk_compiler_func::consts_idx, duk_compiler_ctx::curr_func, duk_compiler_func::decls_idx, DUK__BC_INITIAL_INSTS, DUK__FUNCTION_INIT_REQUIRE_SLOTS, DUK_ASSERT, DUK_BW_INIT_PUSHBUF, duk_get_hbuffer(), DUK_GET_HOBJECT_POSIDX, duk_get_top(), DUK_HBUFFER_HAS_DYNAMIC, DUK_HBUFFER_HAS_EXTERNAL, DUK_MEMZERO, duk_push_array(), duk_push_dynamic_buffer, duk_push_object_internal(), duk_require_stack(), duk_compiler_func::fnum_next, duk_compiler_func::funcs_idx, duk_compiler_func::h_argnames, duk_compiler_func::h_consts, duk_compiler_func::h_decls, duk_compiler_func::h_funcs, duk_compiler_func::h_labelinfos, duk_compiler_func::h_labelnames, duk_compiler_func::h_name, duk_compiler_func::h_varmap, duk_compiler_func::labelinfos_idx, duk_compiler_func::labelnames_idx, NULL, duk_compiler_ctx::thr, and duk_compiler_func::varmap_idx.
Referenced by duk__js_compile_raw(), and duk__parse_func_like_fnum().
DUK_LOCAL_DECL void duk__init_varmap_and_prologue_for_pass2 | ( | duk_compiler_ctx * | comp_ctx, |
duk_reg_t * | out_stmt_value_reg ) |
Definition at line 6806 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::argnames_idx, duk_compiler_ctx::curr_func, duk_compiler_func::decls_idx, DUK__ALLOCTEMP, DUK__ALLOCTEMPS, duk__emit_a_b_c(), duk__emit_a_bc(), DUK__EMIT_FLAG_NO_SHUFFLE_A, duk__getconst(), duk__hstring_is_eval_or_arguments(), DUK__SETTEMP, DUK__SETTEMP_CHECKMAX, DUK_ASSERT, DUK_ASSERT_TOP, DUK_BC_DECLVAR_FLAG_FUNC_DECL, DUK_BC_DECLVAR_FLAG_UNDEF_VALUE, DUK_D, DUK_DDD, DUK_DDDPRINT, DUK_DECL_TYPE_FUNC, DUK_DECL_TYPE_VAR, DUK_DPRINT, duk_dup_top(), DUK_ERROR_RANGE, DUK_ERROR_SYNTAX, duk_get_hstring(), duk_get_length(), duk_get_prop(), duk_get_prop_index(), duk_get_top(), duk_get_tval(), duk_has_prop(), duk_has_prop_stridx(), DUK_HSTRING_HAS_STRICT_RESERVED_WORD, DUK_HTHREAD_STRING_LC_ARGUMENTS, DUK_OP_CLOSURE, DUK_OP_DECLVAR, duk_pop(), DUK_PROPDESC_FLAG_CONFIGURABLE, DUK_PROPDESC_FLAG_ENUMERABLE, DUK_PROPDESC_FLAG_WRITABLE, duk_push_int(), duk_push_null(), duk_push_uarridx, duk_put_prop(), DUK_STR_INVALID_ARG_NAME, DUK_STR_REG_LIMIT, DUK_STRIDX_LC_ARGUMENTS, duk_to_int(), DUK_UNREACHABLE, duk_compiler_func::is_arguments_shadowed, duk_compiler_func::is_eval, duk_compiler_func::is_function, duk_compiler_func::is_strict, duk_compiler_func::needs_shuffle, NULL, duk_compiler_func::shuffle1, duk_compiler_func::shuffle2, duk_compiler_func::shuffle3, duk_compiler_func::temp_next, duk_compiler_ctx::thr, and duk_compiler_func::varmap_idx.
Referenced by duk__parse_func_body().
DUK_LOCAL_DECL void duk__insert_jump_entry | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | jump_pc ) |
Definition at line 1580 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, DUK_BW_ADD_PTR, DUK_BW_GET_SIZE, DUK_BW_INSERT_ENSURE_AREA, DUK_ENC_OP_ABC, DUK_ERROR_RANGE, DUK_OP_JUMP, DUK_STR_BYTECODE_LIMIT, DUK_UNLIKELY, DUK_USE_ESBC_MAX_BYTES, duk_compiler_instr::ins, duk_compiler_instr::line, duk_token::start_line, and duk_compiler_ctx::thr.
Referenced by duk__parse_for_stmt().
DUK_LOCAL_DECL duk_bool_t duk__is_whole_get_int32 | ( | duk_double_t | x, |
duk_int32_t * | ival ) |
Definition at line 1837 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK_FP_NORMAL, DUK_FP_ZERO, DUK_FPCLASSIFY, and DUK_SIGNBIT.
Referenced by duk__ispec_toregconst_raw().
DUK_LOCAL_DECL void duk__ispec_toforcedreg | ( | duk_compiler_ctx * | comp_ctx, |
duk_ispec * | x, | ||
duk_reg_t | forced_reg ) |
Definition at line 2120 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__ispec_toregconst_raw(), and DUK_ASSERT.
Referenced by duk__expr_led().
DUK_LOCAL_DECL duk_regconst_t duk__ispec_toregconst_raw | ( | duk_compiler_ctx * | comp_ctx, |
duk_ispec * | x, | ||
duk_reg_t | forced_reg, | ||
duk_small_uint_t | flags ) |
Definition at line 1949 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK__ALLOCTEMP, DUK__CONST_MARKER, duk__emit_a_bc(), duk__emit_extraop_bc(), duk__emit_load_int32(), duk__getconst(), duk__is_whole_get_int32(), DUK__ISTEMP, DUK__IVAL_FLAG_ALLOW_CONST, DUK__IVAL_FLAG_REQUIRE_SHORT, DUK__IVAL_FLAG_REQUIRE_TEMP, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, duk_dup(), DUK_ERROR_INTERNAL_DEFMSG, DUK_EXTRAOP_LDFALSE, DUK_EXTRAOP_LDNULL, DUK_EXTRAOP_LDTRUE, DUK_EXTRAOP_LDUNDEF, duk_get_tval(), DUK_GET_TVAL_POSIDX, DUK_HSTRING_GET_BYTELEN, DUK_ISPEC_REGCONST, DUK_ISPEC_VALUE, DUK_OP_LDCONST, DUK_OP_LDREG, DUK_TAG_BOOLEAN, DUK_TAG_BUFFER, DUK_TAG_LIGHTFUNC, DUK_TAG_NULL, DUK_TAG_OBJECT, DUK_TAG_POINTER, DUK_TAG_STRING, DUK_TAG_UNDEFINED, DUK_TVAL_GET_BOOLEAN, DUK_TVAL_GET_NUMBER, DUK_TVAL_GET_STRING, DUK_TVAL_GET_TAG, DUK_TVAL_IS_NUMBER, DUK_TVAL_IS_UNUSED, DUK_UNREACHABLE, DUK_UNREF, NULL, duk_ispec::regconst, duk_ispec::t, duk_compiler_ctx::thr, and duk_ispec::valstack_idx.
Referenced by duk__expr_led(), duk__expr_nud(), duk__ispec_toforcedreg(), duk__ivalue_toplain_raw(), duk__ivalue_toregconst_raw(), and duk__parse_for_stmt().
DUK_LOCAL_DECL void duk__ivalue_toforcedreg | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x, | ||
duk_int_t | forced_reg ) |
Definition at line 2414 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__ivalue_toregconst_raw(), and DUK_ASSERT.
Referenced by duk__expr_led(), duk__expr_nud(), duk__expr_toforcedreg(), duk__exprtop_toforcedreg(), duk__parse_stmt(), and duk__parse_var_decl().
DUK_LOCAL_DECL void duk__ivalue_toplain | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x ) |
Definition at line 2346 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__ivalue_toplain_raw().
Referenced by duk__expr_led(), and duk__expr_toplain().
DUK_LOCAL_DECL void duk__ivalue_toplain_ignore | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x ) |
Definition at line 2351 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK__GETTEMP, duk__ivalue_toplain_raw(), and DUK__SETTEMP.
Referenced by duk__expr_led(), duk__expr_toplain_ignore(), duk__parse_for_stmt(), and duk__parse_stmt().
DUK_LOCAL_DECL void duk__ivalue_toplain_raw | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x, | ||
duk_reg_t | forced_reg ) |
Definition at line 2130 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_double_union::d, DUK__ALLOCTEMP, duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_extraop_b_c(), DUK__EMIT_FLAG_B_IS_TARGET, DUK__EMIT_FLAG_B_IS_TARGETSOURCE, DUK__ISCONST, duk__ispec_toregconst_raw(), DUK__ISREG, DUK__ISTEMP, DUK__IVAL_FLAG_ALLOW_CONST, DUK__IVAL_FLAG_REQUIRE_SHORT, duk__lookup_lhs(), DUK_ASSERT, duk_concat(), DUK_D, DUK_DBLUNION_NORMALIZE_NAN_CHECK, DUK_DDD, DUK_DDDPRINT, DUK_DPRINT, duk_dup(), DUK_ERROR_INTERNAL_DEFMSG, duk_get_tval(), DUK_GET_TVAL_POSIDX, DUK_ISPEC_REGCONST, DUK_ISPEC_VALUE, DUK_IVAL_ARITH, DUK_IVAL_ARITH_EXTRAOP, DUK_IVAL_NONE, DUK_IVAL_PLAIN, DUK_IVAL_PROP, DUK_IVAL_VAR, DUK_OP_ADD, DUK_OP_DIV, DUK_OP_GETPROP, DUK_OP_GETVAR, DUK_OP_LDCONST, DUK_OP_LDREG, DUK_OP_MUL, DUK_OP_SUB, duk_replace(), DUK_TVAL_GET_NUMBER, DUK_TVAL_IS_NUMBER, DUK_TVAL_IS_STRING, DUK_TVAL_SET_NUMBER, NULL, duk_ivalue::op, duk_ispec::regconst, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__ivalue_toplain(), duk__ivalue_toplain_ignore(), and duk__ivalue_toregconst_raw().
DUK_LOCAL_DECL duk_reg_t duk__ivalue_toreg | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x ) |
Definition at line 2404 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__ivalue_toregconst_raw().
Referenced by duk__expr_led(), duk__exprtop_toreg(), and duk__parse_var_decl().
DUK_LOCAL_DECL duk_regconst_t duk__ivalue_toregconst | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x ) |
Definition at line 2419 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK__IVAL_FLAG_ALLOW_CONST, and duk__ivalue_toregconst_raw().
Referenced by duk__expr_toregconst(), duk__exprtop_toregconst(), and duk__parse_for_stmt().
DUK_LOCAL_DECL duk_regconst_t duk__ivalue_toregconst_raw | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x, | ||
duk_reg_t | forced_reg, | ||
duk_small_uint_t | flags ) |
Definition at line 2369 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__ispec_toregconst_raw(), DUK__IVAL_FLAG_ALLOW_CONST, DUK__IVAL_FLAG_REQUIRE_SHORT, DUK__IVAL_FLAG_REQUIRE_TEMP, duk__ivalue_toplain_raw(), DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, duk_get_tval(), DUK_ISPEC_REGCONST, DUK_IVAL_PLAIN, DUK_UNREF, duk_ivalue::op, duk_ispec::regconst, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__expr_nud(), duk__ivalue_toforcedreg(), duk__ivalue_toreg(), duk__ivalue_toregconst(), and duk__ivalue_totempconst().
DUK_LOCAL_DECL duk_regconst_t duk__ivalue_totempconst | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | x ) |
Definition at line 2423 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK__IVAL_FLAG_ALLOW_CONST, DUK__IVAL_FLAG_REQUIRE_TEMP, and duk__ivalue_toregconst_raw().
Referenced by duk__expr_led().
DUK_LOCAL duk_ret_t duk__js_compile_raw | ( | duk_context * | ctx | ) |
Definition at line 7683 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_lexer_ctx::buf, duk_lexer_ctx::buf_idx, duk__compiler_stkstate::comp_ctx_alloc, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__COMPILE_ENTRY_SLOTS, duk__convert_to_func_template(), duk__init_func_valstack_slots(), duk__parse_func_body(), duk__parse_func_like_raw(), DUK_ASSERT, DUK_COMPILER_TOKEN_LIMIT, duk_get_hbuffer(), duk_get_hstring(), duk_get_top(), DUK_HBUFFER_HAS_DYNAMIC, DUK_HBUFFER_HAS_EXTERNAL, DUK_JS_COMPILE_FLAG_EVAL, DUK_JS_COMPILE_FLAG_FUNCEXPR, DUK_JS_COMPILE_FLAG_STRICT, DUK_LEXER_SETPOINT, duk_push_dynamic_buffer, duk_push_hstring_stridx(), duk_push_undefined(), duk_require_pointer(), duk_require_stack(), DUK_STRIDX_EVAL, DUK_STRIDX_GLOBAL, DUK_TOK_FUNCTION, DUK_USE_COMPILER_RECLIMIT, duk__compiler_stkstate::flags, duk_compiler_ctx::h_filename, duk_compiler_func::h_name, duk_compiler_func::is_decl, duk_compiler_func::is_eval, duk_compiler_func::is_function, duk_compiler_func::is_global, duk_compiler_func::is_setget, duk_compiler_func::is_strict, duk_compiler_ctx::lex, duk__compiler_stkstate::lex_pt_alloc, duk_lexer_point::line, NULL, duk_compiler_func::num_formals, duk_lexer_point::offset, duk_compiler_ctx::prev_token, duk_compiler_ctx::recursion_limit, duk_lexer_ctx::slot1_idx, duk_lexer_ctx::slot2_idx, duk_token::start_line, duk_token::str1, duk_token::str2, duk_lexer_ctx::thr, duk_compiler_ctx::thr, duk_compiler_ctx::tok11_idx, duk_compiler_ctx::tok12_idx, duk_compiler_ctx::tok21_idx, duk_compiler_ctx::tok22_idx, and duk_lexer_ctx::token_limit.
Referenced by duk_js_compile().
DUK_LOCAL_DECL void duk__lookup_active_label | ( | duk_compiler_ctx * | comp_ctx, |
duk_hstring * | h_label, | ||
duk_bool_t | is_break, | ||
duk_int_t * | out_label_id, | ||
duk_int_t * | out_label_catch_depth, | ||
duk_int_t * | out_label_pc, | ||
duk_bool_t * | out_is_closest ) |
Definition at line 2642 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_labelinfo::catch_depth, duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, DUK_HBUFFER_DYNAMIC_GET_DATA_PTR, DUK_HBUFFER_GET_SIZE, DUK_HTHREAD_STRING_EMPTY_STRING, DUK_LABEL_FLAG_ALLOW_BREAK, DUK_LABEL_FLAG_ALLOW_CONTINUE, DUK_STR_INVALID_LABEL, DUK_UNREF, duk_labelinfo::flags, duk_labelinfo::h_label, duk_compiler_func::h_labelinfos, duk_hthread::heap, duk_labelinfo::label_id, match(), duk_labelinfo::pc_label, and duk_compiler_ctx::thr.
Referenced by duk__parse_break_or_continue_stmt().
DUK_LOCAL_DECL duk_reg_t duk__lookup_active_register_binding | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 2439 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, duk_get_hstring(), duk_get_prop(), duk_get_tval(), DUK_HTHREAD_STRING_LC_ARGUMENTS, duk_is_number(), duk_pop(), duk_to_int(), duk_compiler_func::id_access_arguments, duk_compiler_func::id_access_slow, NULL, duk_compiler_ctx::thr, duk_compiler_func::varmap_idx, and duk_compiler_func::with_depth.
Referenced by duk__lookup_lhs().
DUK_LOCAL_DECL duk_bool_t duk__lookup_lhs | ( | duk_compiler_ctx * | ctx, |
duk_reg_t * | out_reg_varbind, | ||
duk_regconst_t * | out_rc_varname ) |
Definition at line 2505 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__getconst(), duk__lookup_active_register_binding(), duk_dup_top(), duk_pop(), and duk_compiler_ctx::thr.
Referenced by duk__expr_led(), duk__expr_nud(), duk__ivalue_toplain_raw(), duk__parse_for_stmt(), and duk__parse_var_decl().
DUK_LOCAL_DECL void duk__nud_array_literal | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 2740 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), DUK__ALLOCTEMP, DUK__BP_COMMA, duk__emit_a_b_c(), duk__emit_extraop_b_c(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EMIT_FLAG_B_IS_TARGET, DUK__EMIT_FLAG_NO_SHUFFLE_C, duk__emit_load_int32(), duk__expr_toforcedreg(), DUK__GETTEMP, DUK__MAX_ARRAY_INIT_VALUES, DUK__SETTEMP, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, DUK_EXTRAOP_NEWARR, DUK_EXTRAOP_SETALEN, DUK_ISPEC_REGCONST, DUK_IVAL_PLAIN, DUK_OP_MPUTARR, DUK_STR_INVALID_ARRAY_LITERAL, DUK_TOK_COMMA, DUK_TOK_LBRACKET, DUK_TOK_RBRACKET, duk_compiler_ctx::prev_token, duk_ispec::regconst, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, and duk_ivalue::x1.
Referenced by duk__expr_nud().
DUK_LOCAL_DECL void duk__nud_object_literal | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 2948 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMP, DUK__BP_COMMA, duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_extraop_b_c(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EMIT_FLAG_B_IS_TARGET, DUK__EMIT_FLAG_NO_SHUFFLE_C, duk__expr_toforcedreg(), duk__getconst(), DUK__GETTEMP, DUK__MAX_OBJECT_INIT_PAIRS, duk__nud_object_literal_key_check(), DUK__OBJ_LIT_KEY_GET, DUK__OBJ_LIT_KEY_PLAIN, DUK__OBJ_LIT_KEY_SET, duk__parse_func_like_fnum(), DUK__SETTEMP, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, DUK_EXTRAOP_INITGET, DUK_EXTRAOP_INITSET, DUK_EXTRAOP_NEWOBJ, duk_get_tval(), DUK_HTHREAD_STRING_GET, DUK_HTHREAD_STRING_SET, duk_is_string(), DUK_ISPEC_REGCONST, DUK_IVAL_PLAIN, DUK_OP_CLOSURE, DUK_OP_LDCONST, DUK_OP_MPUTOBJ, duk_pop(), duk_push_hstring(), duk_push_number(), duk_push_object(), DUK_STR_INVALID_OBJECT_LITERAL, duk_to_string(), DUK_TOK_COLON, DUK_TOK_COMMA, DUK_TOK_IDENTIFIER, DUK_TOK_LCURLY, DUK_TOK_NUMBER, DUK_TOK_RCURLY, DUK_TOK_STRING, NULL, duk_token::num, duk_compiler_ctx::prev_token, duk_ispec::regconst, duk_token::str1, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_token::t_nores, duk_compiler_ctx::thr, and duk_ivalue::x1.
Referenced by duk__expr_nud().
DUK_LOCAL_DECL duk_bool_t duk__nud_object_literal_key_check | ( | duk_compiler_ctx * | comp_ctx, |
duk_small_uint_t | new_key_flags ) |
Definition at line 2890 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK__OBJ_LIT_KEY_GET, DUK__OBJ_LIT_KEY_PLAIN, DUK__OBJ_LIT_KEY_SET, DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, duk_dup(), duk_get_prop(), duk_get_tval(), duk_is_string(), duk_pop(), duk_push_int(), duk_put_prop(), duk_to_int(), duk_compiler_func::is_strict, and duk_compiler_ctx::thr.
Referenced by duk__nud_object_literal().
DUK_LOCAL_DECL duk_int_t duk__parse_arguments | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 3194 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance_expect(), DUK__ALLOCTEMP, DUK__BP_COMMA, duk__expr_toforcedreg(), DUK__SETTEMP, DUK_DDD, DUK_DDDPRINT, DUK_TOK_COMMA, DUK_TOK_RPAREN, duk_compiler_ctx::prev_token, and duk_token::t.
Referenced by duk__expr_led(), and duk__expr_nud().
DUK_LOCAL_DECL void duk__parse_break_or_continue_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 5732 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_token::allow_auto_semi, duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__emit_extraop_bc(), duk__emit_jump(), duk__lookup_active_label(), DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, DUK_EXTRAOP_BREAK, DUK_EXTRAOP_CONTINUE, DUK_HTHREAD_STRING_EMPTY_STRING, DUK_STR_INVALID_BREAK_CONT_LABEL, DUK_TOK_BREAK, DUK_TOK_IDENTIFIER, DUK_TOK_SEMICOLON, DUK_UNREF, duk_token::lineterm, NULL, duk_token::str1, duk_token::t, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_do_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_int_t | pc_label_site ) |
Definition at line 5672 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__advance(), duk__advance_expect(), DUK__BP_FOR_EXPR, duk__emit_if_false_skip(), duk__emit_jump(), duk__exprtop_toregconst(), duk__get_current_pc(), duk__parse_stmt(), duk__patch_jump_here(), DUK_DDD, DUK_DDDPRINT, DUK_TOK_LPAREN, DUK_TOK_RPAREN, and DUK_TOK_WHILE.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_for_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_int_t | pc_label_site ) |
Definition at line 5071 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMPS, DUK__BP_FOR_EXPR, duk__emit_a_b_c(), duk__emit_a_bc(), duk__emit_extraop_b_c(), duk__emit_extraop_only(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EMIT_FLAG_B_IS_TARGET, DUK__EMIT_FLAG_RESERVE_JUMPSLOT, duk__emit_if_false_skip(), duk__emit_jump(), duk__emit_jump_empty(), DUK__EXPR_FLAG_ALLOW_EMPTY, DUK__EXPR_FLAG_REJECT_IN, duk__expr_is_empty(), duk__exprtop(), duk__exprtop_toreg(), duk__get_current_pc(), DUK__GETTEMP, duk__insert_jump_entry(), duk__ispec_toregconst_raw(), DUK__IVAL_FLAG_ALLOW_CONST, duk__ivalue_toplain_ignore(), duk__ivalue_toregconst(), duk__lookup_lhs(), duk__parse_stmt(), duk__parse_var_decl(), duk__patch_jump(), DUK__SETTEMP, DUK_DDD, DUK_DDDPRINT, duk_dup(), DUK_ERROR_SYNTAX, DUK_EXTRAOP_INITENUM, DUK_EXTRAOP_INVLHS, DUK_EXTRAOP_NEXTENUM, DUK_IVAL_PROP, DUK_IVAL_VAR, DUK_OP_LDREG, DUK_OP_PUTPROP, DUK_OP_PUTVAR, DUK_STR_INVALID_FOR, DUK_TOK_COMMA, DUK_TOK_IN, DUK_TOK_LPAREN, DUK_TOK_RPAREN, DUK_TOK_SEMICOLON, DUK_TOK_VAR, duk_compiler_ctx::emit_jumpslot_pc, duk_token::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_func_body | ( | duk_compiler_ctx * | comp_ctx, |
duk_bool_t | expect_eof, | ||
duk_bool_t | implicit_return_value, | ||
duk_small_int_t | expect_token ) |
Definition at line 7134 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMP, duk__emit_a_b(), duk__emit_extraop_bc(), DUK__EMIT_FLAG_NO_SHUFFLE_A, DUK__FUNCTION_BODY_REQUIRE_SLOTS, DUK__GETTEMP, duk__hstring_is_eval_or_arguments(), duk__init_varmap_and_prologue_for_pass2(), duk__parse_stmts(), duk__peephole_optimize_bytecode(), DUK__RECURSION_DECREASE, DUK__RECURSION_INCREASE, duk__reset_func_for_pass2(), duk__update_lineinfo_currtoken(), DUK_ASSERT, DUK_BC_RETURN_FLAG_HAVE_RETVAL, DUK_D, DUK_DDD, DUK_DDDPRINT, DUK_DPRINT, DUK_ERROR_INTERNAL_DEFMSG, DUK_ERROR_SYNTAX, DUK_EXTRAOP_LDUNDEF, DUK_HSTRING_HAS_RESERVED_WORD, DUK_HSTRING_HAS_STRICT_RESERVED_WORD, DUK_INT_MAX, DUK_LEXER_GETPOINT, DUK_LEXER_SETPOINT, DUK_OP_RETURN, duk_require_stack(), DUK_STR_INVALID_FUNC_NAME, DUK_TOK_LCURLY, duk_compiler_func::h_name, duk_compiler_func::id_access_arguments, duk_compiler_func::id_access_slow, duk_compiler_func::in_directive_prologue, duk_compiler_func::in_scanning, duk_compiler_func::is_function, duk_compiler_func::is_setget, duk_compiler_func::is_strict, duk_compiler_func::label_next, duk_compiler_ctx::lex, duk_compiler_func::may_direct_eval, duk_compiler_func::needs_shuffle, NULL, duk_compiler_func::reg_stmt_value, duk_token::start_line, duk_compiler_func::stmt_next, duk_token::t, duk_compiler_func::temp_first, duk_compiler_func::temp_next, and duk_compiler_ctx::thr.
Referenced by duk__js_compile_raw(), and duk__parse_func_like_raw().
DUK_LOCAL_DECL void duk__parse_func_formals | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 7413 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::argnames_idx, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, duk_get_length(), duk_push_hstring(), duk_put_prop_index(), DUK_TOK_COMMA, DUK_TOK_IDENTIFIER, DUK_TOK_RPAREN, NULL, duk_token::str1, duk_token::t, and duk_compiler_ctx::thr.
Referenced by duk__parse_func_like_raw().
DUK_LOCAL_DECL duk_int_t duk__parse_func_like_fnum | ( | duk_compiler_ctx * | comp_ctx, |
duk_bool_t | is_decl, | ||
duk_bool_t | is_setget ) |
Definition at line 7569 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), duk__init_func_valstack_slots(), DUK__MAX_FUNCS, duk__parse_func_like_raw(), DUK_ASC_RCURLY, DUK_ASSERT, DUK_ASSERT_TOP, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_RANGE, duk_get_length(), duk_get_prop_index(), duk_get_top(), DUK_LEXER_SETPOINT, DUK_MEMCPY, DUK_MEMZERO, duk_pop(), duk_push_int(), duk_push_size_t, duk_put_prop_index(), duk_set_top(), DUK_STR_FUNC_LIMIT, duk_to_int(), DUK_TOK_RCURLY, duk_compiler_func::fnum_next, duk_compiler_func::funcs_idx, duk_compiler_func::in_scanning, duk_lexer_ctx::input, duk_compiler_func::is_decl, duk_compiler_func::is_eval, duk_compiler_func::is_function, duk_compiler_func::is_global, duk_compiler_func::is_notail, duk_compiler_func::is_setget, duk_compiler_func::is_strict, duk_compiler_ctx::lex, duk_lexer_point::line, duk_compiler_func::num_formals, duk_lexer_point::offset, duk_compiler_ctx::prev_token, duk_token::start_line, duk_token::start_offset, duk_token::t, and duk_compiler_ctx::thr.
Referenced by duk__expr_nud(), duk__nud_object_literal(), and duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_func_like_raw | ( | duk_compiler_ctx * | comp_ctx, |
duk_bool_t | is_decl, | ||
duk_bool_t | is_setget ) |
Definition at line 7461 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), duk__convert_to_func_template(), duk__parse_func_body(), duk__parse_func_formals(), duk__update_lineinfo_currtoken(), DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_ERROR_SYNTAX, duk_get_hstring(), duk_push_hstring(), duk_push_number(), DUK_STR_FUNC_NAME_REQUIRED, DUK_STR_INVALID_GETSET_NAME, duk_to_string(), DUK_TOK_IDENTIFIER, DUK_TOK_LCURLY, DUK_TOK_LPAREN, DUK_TOK_NUMBER, DUK_TOK_RPAREN, DUK_TOK_STRING, duk_compiler_func::h_name, duk_compiler_func::is_decl, duk_compiler_func::is_eval, duk_compiler_func::is_function, duk_compiler_func::is_global, duk_compiler_func::is_setget, NULL, duk_token::num, duk_compiler_func::num_formals, duk_token::str1, duk_token::t, duk_token::t_nores, and duk_compiler_ctx::thr.
Referenced by duk__js_compile_raw(), and duk__parse_func_like_fnum().
DUK_LOCAL_DECL void duk__parse_if_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 5625 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__BP_FOR_EXPR, duk__emit_if_true_skip(), duk__emit_jump_empty(), duk__exprtop_toregconst(), DUK__GETTEMP, duk__parse_stmt(), duk__patch_jump_here(), DUK__SETTEMP, DUK_DDD, DUK_DDDPRINT, DUK_TOK_ELSE, DUK_TOK_LPAREN, DUK_TOK_RPAREN, and duk_token::t.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_return_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 5787 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_token::allow_auto_semi, duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), DUK__BP_FOR_EXPR, duk__emit_a_b(), DUK__EMIT_FLAG_NO_SHUFFLE_A, duk__exprtop_toregconst(), duk__get_current_pc(), duk__get_instr_ptr(), DUK__ISTEMP, DUK_ASSERT, DUK_BC_CALL_FLAG_TAILCALL, DUK_BC_RETURN_FLAG_HAVE_RETVAL, DUK_DDD, DUK_DDDPRINT, DUK_DEC_OP, DUK_ENC_OP_A_B_C, DUK_ERROR_SYNTAX, DUK_OP_CALL, DUK_OP_CALLI, DUK_OP_RETURN, DUK_STR_INVALID_RETURN, DUK_TOK_SEMICOLON, DUK_UNREF, duk_compiler_instr::ins, duk_compiler_func::is_function, duk_token::lineterm, NULL, duk_token::t, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_bool_t | allow_source_elem ) |
Definition at line 6202 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_token::allow_auto_semi, duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk_compiler_func::decls_idx, duk__add_label(), duk__advance(), DUK__ALLOW_AUTO_SEMI_ALWAYS, DUK__BP_FOR_EXPR, duk__emit_extraop_bc(), duk__emit_extraop_only(), DUK__EXPR_FLAG_REQUIRE_INIT, duk__exprtop(), duk__get_current_pc(), DUK__GETTEMP, DUK__HAS_TERM, DUK__HAS_VAL, DUK__IS_TERMINAL, duk__ivalue_toforcedreg(), duk__ivalue_toplain_ignore(), duk__parse_break_or_continue_stmt(), duk__parse_do_stmt(), duk__parse_for_stmt(), duk__parse_func_like_fnum(), duk__parse_if_stmt(), duk__parse_return_stmt(), duk__parse_stmts(), duk__parse_switch_stmt(), duk__parse_throw_stmt(), duk__parse_try_stmt(), duk__parse_var_stmt(), duk__parse_while_stmt(), duk__parse_with_stmt(), duk__patch_jump_here(), DUK__RECURSION_DECREASE, DUK__RECURSION_INCREASE, duk__reset_labels_to_length(), DUK__SETTEMP, DUK__STILL_PROLOGUE, duk__stmt_label_site(), duk__update_label_flags(), DUK_ASSERT, DUK_DD, DUK_DDD, DUK_DDDPRINT, DUK_DDPRINT, DUK_DECL_TYPE_FUNC, DUK_ERROR_SYNTAX, DUK_EXTRAOP_DEBUGGER, DUK_EXTRAOP_ENDLABEL, duk_get_hstring(), duk_get_length(), duk_get_prop_index(), duk_get_prop_stridx(), duk_get_tval(), DUK_HSTRING_GET_BYTELEN, DUK_HSTRING_GET_DATA, DUK_HTHREAD_STRING_EMPTY_STRING, DUK_ISPEC_VALUE, DUK_IVAL_PLAIN, DUK_IVAL_VAR, DUK_LABEL_FLAG_ALLOW_BREAK, DUK_LABEL_FLAG_ALLOW_CONTINUE, duk_pop_n(), duk_push_hstring(), duk_push_int(), duk_put_prop_index(), DUK_STR_FUNC_STMT_NOT_ALLOWED, DUK_STR_UNTERMINATED_STMT, DUK_STRIDX_NAME, DUK_STRNCMP, DUK_TOK_BREAK, DUK_TOK_COLON, DUK_TOK_CONST, DUK_TOK_CONTINUE, DUK_TOK_DEBUGGER, DUK_TOK_DO, DUK_TOK_FOR, DUK_TOK_FUNCTION, DUK_TOK_IDENTIFIER, DUK_TOK_IF, DUK_TOK_LCURLY, DUK_TOK_RETURN, DUK_TOK_SEMICOLON, DUK_TOK_STRING, DUK_TOK_SWITCH, DUK_TOK_THROW, DUK_TOK_TRY, DUK_TOK_VAR, DUK_TOK_WHILE, DUK_TOK_WITH, DUK_TVAL_IS_STRING, DUK_UNREF, duk_compiler_func::funcs_idx, duk_compiler_func::in_directive_prologue, duk_compiler_func::in_scanning, duk_compiler_func::is_notail, duk_compiler_func::is_strict, duk_compiler_func::labelnames_idx, duk_compiler_func::led_count, duk_compiler_func::nud_count, NULL, duk_token::num_escapes, duk_compiler_ctx::prev_token, duk_compiler_func::reg_stmt_value, duk_compiler_func::stmt_next, duk_token::str1, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_compiler_func::with_depth, and duk_ivalue::x1.
Referenced by duk__parse_do_stmt(), duk__parse_for_stmt(), duk__parse_if_stmt(), duk__parse_stmts(), duk__parse_switch_stmt(), duk__parse_while_stmt(), and duk__parse_with_stmt().
DUK_LOCAL_DECL void duk__parse_stmts | ( | duk_compiler_ctx * | comp_ctx, |
duk_bool_t | allow_source_elem, | ||
duk_bool_t | expect_eof ) |
Definition at line 6718 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), DUK__PARSE_STATEMENTS_SLOTS, duk__parse_stmt(), DUK_DDD, DUK_DDDPRINT, duk_get_top(), DUK_ISPEC_VALUE, DUK_IVAL_PLAIN, DUK_MEMZERO, duk_pop_2(), duk_push_undefined(), duk_require_stack(), DUK_TOK_EOF, DUK_TOK_RCURLY, duk_token::t, duk_ispec::t, duk_ivalue::t, duk_compiler_ctx::thr, duk_ispec::valstack_idx, duk_ivalue::x1, and duk_ivalue::x2.
Referenced by duk__parse_func_body(), duk__parse_stmt(), and duk__parse_try_stmt().
DUK_LOCAL_DECL void duk__parse_switch_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_int_t | pc_label_site ) |
Definition at line 5426 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMP, DUK__BP_FOR_EXPR, duk__emit_a_b_c(), duk__emit_if_true_skip(), duk__emit_jump_empty(), duk__exprtop_toregconst(), duk__get_current_pc(), DUK__GETTEMP, duk__parse_stmt(), duk__patch_jump(), duk__patch_jump_here(), DUK__SETTEMP, DUK_ASSERT, DUK_DD, DUK_DDD, DUK_DDDPRINT, DUK_DDPRINT, DUK_ERROR_SYNTAX, DUK_OP_SEQ, DUK_STR_INVALID_SWITCH, DUK_TOK_CASE, DUK_TOK_COLON, DUK_TOK_DEFAULT, DUK_TOK_LCURLY, DUK_TOK_LPAREN, DUK_TOK_RCURLY, DUK_TOK_RPAREN, duk_token::t, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_throw_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 5887 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), DUK__BP_FOR_EXPR, duk__emit_extraop_bc(), duk__exprtop_toreg(), DUK_ERROR_SYNTAX, DUK_EXTRAOP_THROW, DUK_STR_INVALID_THROW, duk_token::lineterm, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_try_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 5904 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMPS, duk__emit_a_bc(), duk__emit_extraop_b(), duk__emit_extraop_only(), DUK__EMIT_FLAG_A_IS_SOURCE, duk__emit_invalid(), duk__get_current_pc(), duk__getconst(), duk__parse_stmts(), duk__patch_jump(), duk__patch_jump_here(), duk__patch_trycatch(), DUK_ASSERT, DUK_BC_TRYCATCH_FLAG_CATCH_BINDING, DUK_BC_TRYCATCH_FLAG_HAVE_CATCH, DUK_BC_TRYCATCH_FLAG_HAVE_FINALLY, DUK_DDD, DUK_DDDPRINT, duk_del_prop(), duk_dup_top(), DUK_ERROR_SYNTAX, DUK_EXTRAOP_ENDCATCH, DUK_EXTRAOP_ENDFIN, DUK_EXTRAOP_ENDTRY, duk_get_int(), duk_get_prop(), duk_get_top(), duk_get_tval(), DUK_HTHREAD_STRING_EVAL, DUK_HTHREAD_STRING_LC_ARGUMENTS, duk_is_null(), duk_is_number(), duk_is_undefined(), DUK_OP_LDCONST, DUK_OP_PUTVAR, duk_pop(), duk_push_hstring(), duk_push_int(), duk_push_null(), duk_put_prop(), DUK_STR_INVALID_TRY, DUK_TOK_CATCH, DUK_TOK_FINALLY, DUK_TOK_IDENTIFIER, DUK_TOK_LCURLY, DUK_TOK_LPAREN, DUK_TOK_RPAREN, DUK_UNREF, duk_compiler_func::is_strict, NULL, duk_token::str1, duk_token::t, duk_compiler_ctx::thr, and duk_compiler_func::varmap_idx.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_var_decl | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | expr_flags, | ||
duk_reg_t * | out_reg_varbind, | ||
duk_regconst_t * | out_rc_varname ) |
Definition at line 4976 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_compiler_ctx::curr_token, duk_compiler_func::decls_idx, duk__advance(), DUK__BP_COMMA, duk__emit_a_bc(), DUK__EMIT_FLAG_A_IS_SOURCE, DUK__EXPR_FLAG_REQUIRE_INIT, duk__exprtop(), duk__hstring_is_eval_or_arguments_in_strict_mode(), duk__ivalue_toforcedreg(), duk__ivalue_toreg(), duk__lookup_lhs(), DUK_ASSERT, DUK_DDD, DUK_DDDPRINT, DUK_DECL_TYPE_VAR, duk_dup_top(), DUK_ERROR_SYNTAX, duk_get_length(), DUK_OP_PUTVAR, duk_pop(), duk_push_hstring(), duk_push_int(), duk_put_prop_index(), DUK_STR_INVALID_VAR_DECLARATION, DUK_TOK_EQUALSIGN, DUK_TOK_IDENTIFIER, duk_compiler_func::in_scanning, NULL, duk_token::str1, duk_token::t, and duk_compiler_ctx::thr.
Referenced by duk__parse_for_stmt(), and duk__parse_var_stmt().
DUK_LOCAL_DECL void duk__parse_var_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_small_uint_t | expr_flags ) |
Definition at line 5054 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_token, duk__advance(), duk__parse_var_decl(), DUK_TOK_COMMA, and duk_token::t.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_while_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res, | ||
duk_int_t | pc_label_site ) |
Definition at line 5699 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__advance(), duk__advance_expect(), DUK__BP_FOR_EXPR, duk__emit_if_true_skip(), duk__emit_jump(), duk__emit_jump_empty(), duk__exprtop_toregconst(), duk__get_current_pc(), DUK__GETTEMP, duk__parse_stmt(), duk__patch_jump_here(), DUK__SETTEMP, DUK_DDD, DUK_DDDPRINT, DUK_TOK_LPAREN, and DUK_TOK_RPAREN.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__parse_with_stmt | ( | duk_compiler_ctx * | comp_ctx, |
duk_ivalue * | res ) |
Definition at line 6139 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::catch_depth, duk_compiler_ctx::curr_func, duk__advance(), duk__advance_expect(), DUK__ALLOCTEMPS, DUK__BP_FOR_EXPR, duk__emit_a_bc(), duk__emit_extraop_only(), DUK__EMIT_FLAG_NO_SHUFFLE_A, duk__emit_invalid(), duk__exprtop_toforcedreg(), duk__get_current_pc(), duk__parse_stmt(), duk__patch_jump(), DUK_BC_TRYCATCH_FLAG_WITH_BINDING, DUK_ERROR_SYNTAX, DUK_EXTRAOP_ENDTRY, DUK_OP_TRYCATCH, DUK_STR_WITH_IN_STRICT_MODE, DUK_TOK_LPAREN, DUK_TOK_RPAREN, duk_compiler_func::is_strict, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__patch_jump | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | jump_pc, | ||
duk_int_t | target_pc ) |
Definition at line 1615 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__get_instr_ptr(), DUK_ASSERT, DUK_BC_JUMP_BIAS, DUK_DDD, DUK_DDDPRINT, DUK_ENC_OP_ABC, DUK_OP_JUMP, duk_compiler_instr::ins, and NULL.
Referenced by duk__parse_for_stmt(), duk__parse_switch_stmt(), duk__parse_try_stmt(), duk__parse_with_stmt(), and duk__patch_jump_here().
DUK_LOCAL_DECL void duk__patch_jump_here | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | jump_pc ) |
Definition at line 1639 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__get_current_pc(), and duk__patch_jump().
Referenced by duk__expr_led(), duk__parse_do_stmt(), duk__parse_if_stmt(), duk__parse_stmt(), duk__parse_switch_stmt(), duk__parse_try_stmt(), and duk__parse_while_stmt().
DUK_LOCAL_DECL void duk__patch_trycatch | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | ldconst_pc, | ||
duk_int_t | trycatch_pc, | ||
duk_regconst_t | reg_catch, | ||
duk_regconst_t | const_varname, | ||
duk_small_uint_t | flags ) |
Definition at line 1643 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK__CONST_MARKER, duk__get_instr_ptr(), DUK_ASSERT, DUK_ASSERT_DISABLE, DUK_BC_A_MAX, DUK_BC_A_MIN, DUK_BC_BC_MAX, DUK_D, DUK_DEC_OP, DUK_DPRINT, DUK_ENC_OP_A, DUK_ENC_OP_A_BC, DUK_ERROR_RANGE, DUK_EXTRAOP_NOP, DUK_OP_EXTRA, DUK_OP_LDCONST, DUK_OP_TRYCATCH, DUK_STR_REG_LIMIT, duk_compiler_instr::ins, NULL, and duk_compiler_ctx::thr.
Referenced by duk__parse_try_stmt().
DUK_LOCAL void duk__peephole_optimize_bytecode | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1708 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_BC_JUMP_BIAS, DUK_BW_GET_BASEPTR, DUK_BW_GET_SIZE, DUK_COMPILER_PEEPHOLE_MAXITER, DUK_DD, DUK_DDD, DUK_DDDPRINT, DUK_DDPRINT, DUK_DEC_ABC, DUK_DEC_OP, DUK_ENC_OP_ABC, DUK_INT_MAX, DUK_OP_JUMP, duk_compiler_instr::ins, and duk_compiler_ctx::thr.
Referenced by duk__parse_func_body().
DUK_LOCAL void duk__recursion_decrease | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 389 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK_ASSERT, NULL, and duk_compiler_ctx::recursion_depth.
DUK_LOCAL void duk__recursion_increase | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 380 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References DUK_ASSERT, DUK_ERROR_RANGE, DUK_STR_COMPILER_RECURSION_LIMIT, NULL, duk_compiler_ctx::recursion_depth, duk_compiler_ctx::recursion_limit, and duk_compiler_ctx::thr.
DUK_LOCAL_DECL void duk__reset_func_for_pass2 | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 552 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_func::bw_code, duk_compiler_ctx::curr_func, DUK_ASSERT, DUK_BW_RESET_SIZE, DUK_GET_HOBJECT_POSIDX, duk_hbuffer_reset(), duk_hobject_set_length_zero(), duk_push_object_internal(), duk_replace(), duk_compiler_func::fnum_next, duk_compiler_func::h_consts, duk_compiler_func::h_labelinfos, duk_compiler_func::h_labelnames, duk_compiler_func::h_varmap, NULL, duk_compiler_ctx::thr, and duk_compiler_func::varmap_idx.
Referenced by duk__parse_func_body().
DUK_LOCAL_DECL void duk__reset_labels_to_length | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | len ) |
Definition at line 2715 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_hbuffer_resize(), duk_push_int(), duk_put_prop_stridx(), DUK_STRIDX_LENGTH, duk_compiler_func::h_labelinfos, duk_compiler_func::labelnames_idx, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__settemp_checkmax | ( | duk_compiler_ctx * | comp_ctx, |
duk_reg_t | temp_next ) |
Definition at line 1878 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk_compiler_func::temp_max, and duk_compiler_func::temp_next.
DUK_LOCAL_DECL duk_int_t duk__stmt_label_site | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | label_id ) |
Definition at line 6179 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, duk__emit_extraop_bc(), duk__emit_invalid(), DUK_DDD, DUK_DDDPRINT, DUK_EXTRAOP_LABEL, and duk_compiler_func::label_next.
Referenced by duk__parse_stmt().
DUK_LOCAL_DECL void duk__update_label_flags | ( | duk_compiler_ctx * | comp_ctx, |
duk_int_t | label_id, | ||
duk_small_uint_t | flags ) |
Definition at line 2601 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, DUK_DDD, DUK_DDDPRINT, DUK_HBUFFER_DYNAMIC_GET_DATA_PTR, DUK_HBUFFER_GET_SIZE, duk_compiler_func::h_labelinfos, duk_hthread::heap, duk_labelinfo::label_id, and duk_compiler_ctx::thr.
Referenced by duk__parse_stmt().
DUK_LOCAL void duk__update_lineinfo_currtoken | ( | duk_compiler_ctx * | comp_ctx | ) |
Definition at line 1105 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk_compiler_ctx::curr_func, curr_func, duk_compiler_ctx::curr_token, DUK_UNREF, and duk_token::start_line.
Referenced by duk__parse_func_body(), and duk__parse_func_like_raw().
DUK_INTERNAL void duk_js_compile | ( | duk_hthread * | thr, |
const duk_uint8_t * | src_buffer, | ||
duk_size_t | src_length, | ||
duk_small_uint_t | flags ) |
Definition at line 7830 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
References duk__compiler_stkstate::comp_ctx_alloc, duk_hthread::compile_ctx, duk__js_compile_raw(), DUK_ASSERT, DUK_EXEC_SUCCESS, DUK_LEXER_INITCTX, DUK_MEMZERO, duk_push_pointer(), duk_safe_call(), duk_throw(), duk__compiler_stkstate::flags, duk_lexer_ctx::input, duk_lexer_ctx::input_length, duk_compiler_ctx::lex, and NULL.
DUK_LOCAL const duk_uint8_t duk__token_lbp[] |
Definition at line 273 of file duktape-1.5.2/src-separate/duk_js_compiler.c.
Referenced by duk__advance_helper(), and duk__expr_lbp().