diff options
Diffstat (limited to 'foci.c')
-rw-r--r-- | foci.c | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -158,7 +158,13 @@ I(until, "until", &w_begin) LIT(bz), comma, comma, END I(again, "again", &w_until) LIT(b), comma, comma, END I(fwhile, "while", &w_again) FTH(fif), END I(repeat, "repeat", &w_fwhile) swap, FTH(again), FTH(then), END -#define LATEST_INIT &w_repeat +N(pushr, ">r", &w_repeat) { *--rp = (intptr_t **)*sp++; NEXT; } +N(popr, "r>", &w_pushr) { *--sp = (intptr_t)*rp++; NEXT; } +N(pushr2, "2>r", &w_popr) { *--rp = (intptr_t **)sp[1]; + *--rp = (intptr_t **)sp[0]; sp += 2; NEXT; } +N(popr2, "2r>", &w_pushr2) { *--sp = (intptr_t)rp[1]; + *--sp = (intptr_t)rp[0]; rp += 2; NEXT; } +#define LATEST_INIT &w_popr2 void enter_forth(const void * const ptr) { |