Group: comp.lang.forth.mac · Group Profile · Search for Item0 in comp.lang.forth.mac
Author: Roelf Toxopeus
Date: Oct 4, 2006 22:57
... : CONS ( item list -- newlist) swap add-node swap over cell+ ! ; \ make new list from items, which can be lists themself \ nil is always used as first node of a new list : LIST ( item0 ... itemn n-1 -- newlist ) r nil 0 ?do CONS loop ; \ show what is in list (* : show ( list - ) begin dup Nil = invert while dup CAR cr . CDR repeat drop cr ." ...
|