mirror of
https://github.com/nineties/planckforth
synced 2024-12-25 21:58:22 +01:00
Add lib/core.fs
This commit is contained in:
parent
a78b646597
commit
92b7f456f6
2 changed files with 12 additions and 0 deletions
|
@ -2562,6 +2562,7 @@ need-defined (read)
|
|||
then then
|
||||
; execute
|
||||
|
||||
include lib/core.fs
|
||||
|
||||
:noname
|
||||
rdrop
|
||||
|
|
11
lib/core.fs
Normal file
11
lib/core.fs
Normal file
|
@ -0,0 +1,11 @@
|
|||
\ planckforth -
|
||||
\ Copyright (C) 2021 nineties
|
||||
|
||||
\ test/tester.fs and test codes are base on
|
||||
\ https://github.com/gerryjackson/forth2012-test-suite
|
||||
|
||||
defined? roll [unless]
|
||||
: roll ( wn ... w1 n -- w1 wn ... w2 -- )
|
||||
dup 0<= if drop else swap >r 1- recurse r> swap then
|
||||
;
|
||||
[then]
|
Loading…
Reference in a new issue