aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Kummerlaender2017-04-20 15:32:27 +0200
committerAdrian Kummerlaender2017-04-20 15:32:27 +0200
commitf1fc6d8fd21b0bfd302e1e7db01b8d500fb37073 (patch)
treeed0700920b049dde60ff147ce6a7e969a92c0fdf
parent39099c0398a978965a71409bcec67f20a8c02fc7 (diff)
downloadslang-f1fc6d8fd21b0bfd302e1e7db01b8d500fb37073.tar
slang-f1fc6d8fd21b0bfd302e1e7db01b8d500fb37073.tar.gz
slang-f1fc6d8fd21b0bfd302e1e7db01b8d500fb37073.tar.bz2
slang-f1fc6d8fd21b0bfd302e1e7db01b8d500fb37073.tar.xz
slang-f1fc6d8fd21b0bfd302e1e7db01b8d500fb37073.zip
Add further stack ops, comparators to base library
-rw-r--r--library/base.slang7
1 files changed, 7 insertions, 0 deletions
diff --git a/library/base.slang b/library/base.slang
index dc2c725..531b189 100644
--- a/library/base.slang
+++ b/library/base.slang
@@ -1,4 +1,11 @@
+§ nip swp pop ;
+§ tuck swp ovr ;
+
§ abs dup 0 < if -1 * then else ;
§ min ovr ovr < if pop then swp pop else ;
§ max ovr ovr < if swp pop then pop else ;
+
+§ > swp < ;
+§ <= > not ;
+§ >= < not ;