add opcodes
This commit is contained in:
+68
-11
@@ -26,23 +26,80 @@ OPCODE;
|
||||
|
||||
typedef void (*opfunc)(OPCODE);
|
||||
|
||||
OP_DEF (loop_inf)
|
||||
{
|
||||
int opcode_idx;
|
||||
};
|
||||
|
||||
/** Call with 1 argument */
|
||||
OP_DEF (call_1)
|
||||
{
|
||||
int name_literal_idx;
|
||||
int arg_literal_idx;
|
||||
};
|
||||
OP_DEF (nop) { };
|
||||
|
||||
OP_DEF (jmp)
|
||||
{
|
||||
int opcode_idx;
|
||||
};
|
||||
|
||||
OP_DEF (decl) { };
|
||||
|
||||
OP_DEF (named_func_decl) { };
|
||||
|
||||
OP_DEF (anon_func_decl) { };
|
||||
|
||||
OP_DEF (decl_var_global) { };
|
||||
|
||||
OP_DEF (decl_var_local) { };
|
||||
|
||||
/** Call with 1 argument */
|
||||
OP_DEF (call_1)
|
||||
{
|
||||
int name_literal_idx;
|
||||
int arg1_literal_idx;
|
||||
};
|
||||
|
||||
OP_DEF (call_2)
|
||||
{
|
||||
int name_literal_idx;
|
||||
int arg1_literal_idx;
|
||||
int arg2_literal_idx;
|
||||
};
|
||||
|
||||
OP_DEF (call_3)
|
||||
{
|
||||
int name_literal_idx;
|
||||
int arg1_literal_idx;
|
||||
int arg2_literal_idx;
|
||||
int arg3_literal_idx;
|
||||
};
|
||||
|
||||
OP_DEF (call_n) { };
|
||||
|
||||
OP_DEF (list_header) { };
|
||||
|
||||
OP_DEF (list_element) { };
|
||||
|
||||
OP_DEF (list_tail) { };
|
||||
|
||||
OP_DEF (try_begin) { };
|
||||
|
||||
OP_DEF (try_end) { };
|
||||
|
||||
OP_DEF (catch_begin) { };
|
||||
|
||||
OP_DEF (catch_end) { };
|
||||
|
||||
OP_DEF (finally_begin) { };
|
||||
|
||||
OP_DEF (finally_end) { };
|
||||
|
||||
OP_DEF (with_begin) { };
|
||||
|
||||
OP_DEF (with_end) { };
|
||||
|
||||
OP_DEF (loop_inf)
|
||||
{
|
||||
int opcode_idx;
|
||||
};
|
||||
|
||||
OP_DEF (loop_cond_pre) { };
|
||||
|
||||
OP_DEF (loop_cond_post) { };
|
||||
|
||||
OP_DEF (swtch) { };
|
||||
|
||||
OPCODE{
|
||||
opfunc opfunc_ptr;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user