retroforth/example/EvaluateString.forth
crc 8e0c4dd16b add two new examples from Kiyoshi
FossilOrigin-Name: 4f930733947c1331f846262d820152b2a6276dc9cd7cf1fa307129dbff71157c
2019-02-06 12:45:02 +00:00

15 lines
299 B
Forth

## s:(evaluate)
Show string being evaluated
~~~
:s:() (s-) nl '(_ s:prepend '_) s:append s:put nl ;
:s:(evaluate) (s-) dup s:() s:evaluate nl ;
~~~
```
:s:testing (s--) 'Testing_ s:prepend s:put nl ;
's:(evaluate) s:testing
'#2_#3_#136_dump-stack s:(evaluate)
'reset_dump-stack s:(evaluate)
```