From c811a743a1528db1d05970e1aa14162ef7c70b75 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sat, 21 Sep 2019 13:59:39 +0200 Subject: Implement vararg, verify arguments to parameters --- include/bytecode/bytecode.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'include/bytecode') diff --git a/include/bytecode/bytecode.h b/include/bytecode/bytecode.h index 8f786a2..23bc4cf 100644 --- a/include/bytecode/bytecode.h +++ b/include/bytecode/bytecode.h @@ -77,7 +77,8 @@ typedef enum { typedef enum { FUNC_FLAG_NONE = 0, - FUNC_FLAG_EXPORTED = 1 << 0 + FUNC_FLAG_EXPORTED = 1 << 0, + FUNC_FLAG_VARARGS = 1 << 1 } amal_func_flag; typedef u8 AmalOpcodeType; @@ -110,10 +111,13 @@ typedef struct { #pragma pack(push, 1) typedef struct { u8 num_params; + u8 num_return_types; + u8 name_len; + u8 flags; + u32 params_num_pointers; u32 params_fixed_size; - u8 num_return_types; u32 return_types_num_pointers; u32 return_types_fixed_size; } BytecodeHeaderExternFunction; -- cgit v1.2.3