diff options
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/README.md b/README.md new file mode 100644 index 0000000..83cb867 --- /dev/null +++ b/README.md @@ -0,0 +1,14 @@ +# slang + +…a experimental Forth-like stack language implemented in D. + +## Example + + 1 i $ + § incr dup @ 1 + swp $ ; + § print @ . pop ; + § withinBounds @ 10 < ; + § loop i withinBounds if i print i incr loop then else ; + loop + +The above _slang_ code to be entered in the repl prints the numbers from 1 to 9. The repl may be compiled and executed using `dub run` in the project directory. |