Merge branch 'refactor-macroexpand'
This commit is contained in:
commit
8ffaf8129c
|
@ -27,13 +27,12 @@ struct pic_sc {
|
||||||
struct pic_senv *senv;
|
struct pic_senv *senv;
|
||||||
};
|
};
|
||||||
|
|
||||||
#define pic_sc(v) ((struct pic_sc *)pic_ptr(v))
|
|
||||||
#define pic_sc_p(v) (pic_type(v) == PIC_TT_SC)
|
#define pic_sc_p(v) (pic_type(v) == PIC_TT_SC)
|
||||||
|
#define pic_sc_ptr(v) ((struct pic_sc *)pic_ptr(v))
|
||||||
|
|
||||||
#define pic_macro(v) ((struct pic_macro *)pic_ptr(v))
|
|
||||||
#define pic_macro_p(v) (pic_type(v) == PIC_TT_MACRO)
|
#define pic_macro_p(v) (pic_type(v) == PIC_TT_MACRO)
|
||||||
|
#define pic_macro_ptr(v) ((struct pic_macro *)pic_ptr(v))
|
||||||
|
|
||||||
#define pic_senv(v) ((struct pic_senv *)pic_ptr(v))
|
|
||||||
#define pic_senv_p(v) (pic_type(v) == PIC_TT_SENV)
|
#define pic_senv_p(v) (pic_type(v) == PIC_TT_SENV)
|
||||||
#define pic_senv_ptr(v) ((struct pic_senv *)pic_ptr(v))
|
#define pic_senv_ptr(v) ((struct pic_senv *)pic_ptr(v))
|
||||||
|
|
||||||
|
|
|
@ -40,9 +40,9 @@ struct pic_proc {
|
||||||
#define pic_proc_irep_p(proc) ((proc)->kind == PIC_PROC_KIND_IREP)
|
#define pic_proc_irep_p(proc) ((proc)->kind == PIC_PROC_KIND_IREP)
|
||||||
|
|
||||||
#define pic_proc_p(o) (pic_type(o) == PIC_TT_PROC)
|
#define pic_proc_p(o) (pic_type(o) == PIC_TT_PROC)
|
||||||
#define pic_env_p(o) (pic_type(o) == PIC_TT_ENV)
|
|
||||||
|
|
||||||
#define pic_proc_ptr(o) ((struct pic_proc *)pic_ptr(o))
|
#define pic_proc_ptr(o) ((struct pic_proc *)pic_ptr(o))
|
||||||
|
|
||||||
|
#define pic_env_p(o) (pic_type(o) == PIC_TT_ENV)
|
||||||
#define pic_env_ptr(o) ((struct pic_env *)pic_ptr(o))
|
#define pic_env_ptr(o) ((struct pic_env *)pic_ptr(o))
|
||||||
|
|
||||||
struct pic_proc *pic_proc_new(pic_state *, pic_func_t, const char *);
|
struct pic_proc *pic_proc_new(pic_state *, pic_func_t, const char *);
|
||||||
|
|
993
src/macro.c
993
src/macro.c
File diff suppressed because it is too large
Load Diff
|
@ -320,7 +320,7 @@ write_core(struct writer_control *p, pic_value obj)
|
||||||
break;
|
break;
|
||||||
case PIC_TT_SC:
|
case PIC_TT_SC:
|
||||||
xfprintf(file, "#<sc %p: ", pic_ptr(obj));
|
xfprintf(file, "#<sc %p: ", pic_ptr(obj));
|
||||||
write_core(p, pic_sc(obj)->expr);
|
write_core(p, pic_sc_ptr(obj)->expr);
|
||||||
xfprintf(file, ">");
|
xfprintf(file, ">");
|
||||||
break;
|
break;
|
||||||
case PIC_TT_LIB:
|
case PIC_TT_LIB:
|
||||||
|
|
Loading…
Reference in New Issue