support closure call

This commit is contained in:
Yuichi Nishiwaki
2013-10-16 15:30:52 +09:00
parent 49e1f54195
commit 5c8d81e8b5
2 changed files with 40 additions and 5 deletions
+5 -1
View File
@@ -7,9 +7,13 @@
#include "picconf.h"
#include "picrin/value.h"
struct pic_code;
typedef struct pic_callinfo {
struct pic_proc *proc;
int argc;
struct pic_code *pc;
pic_value *sp;
} pic_callinfo;
typedef struct {
@@ -60,7 +64,7 @@ pic_value pic_parse(pic_state *, const char *);
pic_value pic_eval(pic_state *, pic_value, struct pic_env *);
pic_value pic_run(pic_state *, struct pic_proc *, pic_value);
struct pic_proc *pic_codegen(pic_state *, pic_value, struct pic_env*);
struct pic_proc *pic_codegen(pic_state *, pic_value, struct pic_env *);
void pic_raise(pic_state *, const char *);