Add native_call opcode.

This commit is contained in:
e.gavrin
2014-08-21 17:28:28 +04:00
parent 902f8c3414
commit c6a41c167e
3 changed files with 9 additions and 0 deletions
+6
View File
@@ -307,6 +307,12 @@ OP_CODE_DECL (call_n, T_IDX_IDX_IDX,
name_lit_idx,
arg1_lit_idx)
/** lhs = name (arg_list) */
OP_CODE_DECL (native_call, T_IDX_IDX_IDX,
lhs,
name,
arg_list)
/** a = new name (arg_list */
OP_CODE_DECL (construct_decl, T_IDX_IDX_IDX,
lhs,
+2
View File
@@ -428,6 +428,7 @@ do_number_bitwise_logic (struct __int_data *int_data, /**< interpreter context *
#define OP_UNIMPLEMENTED_LIST(op) \
op (call_n) \
op (native_call) \
op (func_decl_n) \
op (varg_list) \
op (retval) \
@@ -2032,6 +2033,7 @@ GETOP_IMPL_3 (assignment, var_left, type_value_right, value_right)
GETOP_IMPL_2 (call_0, lhs, name_lit_idx)
GETOP_IMPL_3 (call_1, lhs, name_lit_idx, arg1_lit_idx)
GETOP_IMPL_3 (call_n, lhs, name_lit_idx, arg1_lit_idx)
GETOP_IMPL_3 (native_call, lhs, name, arg_list)
GETOP_IMPL_2 (func_decl_1, name_lit_idx, arg1_lit_idx)
GETOP_IMPL_3 (func_decl_2, name_lit_idx, arg1_lit_idx, arg2_lit_idx)
GETOP_IMPL_3 (func_decl_n, name_lit_idx, arg1_lit_idx, arg2_lit_idx)
+1
View File
@@ -40,6 +40,7 @@ ecma_completion_value_t (*opfunc) (OPCODE, struct __int_data *);
op (call_0) \
op (call_1) \
op (call_n) \
op (native_call) \
op (construct_decl) \
op (func_decl_0) \
op (func_decl_1) \