X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;ds=sidebyside;f=src%2Fparser.h;h=e774e9ba7df15fb299beeff111a97bab99ed8d3f;hb=7d89722785c32163fe6252ed199c86ba6ee0e28c;hp=55f4f9d75f6d57067adacc2e8a43950530cc2dcd;hpb=e16c15d5936c3b57b05e49570fb9526920de8188;p=m6w6%2Fext-psi diff --git a/src/parser.h b/src/parser.h index 55f4f9d..e774e9b 100644 --- a/src/parser.h +++ b/src/parser.h @@ -262,16 +262,20 @@ static inline void free_decl_abi(decl_abi *abi) { free(abi); } +typedef struct decl_callinfo { + void *sym; + void *info; + size_t argc; + void **args; + void *rval; +} decl_callinfo; + typedef struct decl { decl_abi *abi; decl_arg *func; decl_args *args; struct impl *impl; - struct { - void *sym; - void *info; - void **args; - } call; + decl_callinfo call; } decl; static inline decl* init_decl(decl_abi *abi, decl_arg *func, decl_args *args) { @@ -499,10 +503,18 @@ static inline void free_impl_arg(impl_arg *arg) { free(arg); } +typedef struct impl_vararg { + impl_arg *name; + struct impl_args *args; + token_t *types; + impl_val *values; + void **free_list; +} impl_vararg; + typedef struct impl_args { impl_arg **args; size_t count; - impl_arg *vararg; + impl_vararg vararg; } impl_args; static inline impl_args *init_impl_args(impl_arg *arg) {