ColorForth Implementation of Accumulator Generator


Result on Display

Description will probably follow. Later.

block 114

accumulator generator by mark slicker
---- macro
lit ?dup b8 1, , ;
acc swap over +! @ ; forth
execute push ;
here4 here 3 ? if 1, here4 ; then 2/ 2/ ;
ref here4 swap , ;
adder n -- xt ref here swap lit acc ; ;
---- test
---- foo10 9046068 foo5 9046116
---- 10 adder foo10 ! 5 adder foo5 !
test foo10 @ 5 over execute . 3 over execute . foo5 @ 4 over execute . swap 6 over execute . swap 3 over execute . drop drop ;
ok show black screen text test graph keyboard ;

Hosted by www.Geocities.ws

1