aboutsummaryrefslogtreecommitdiff
path: root/amforth-6.5/common/lib/forth2012/double/d-greater-zero.frt
diff options
context:
space:
mode:
Diffstat (limited to 'amforth-6.5/common/lib/forth2012/double/d-greater-zero.frt')
-rw-r--r--amforth-6.5/common/lib/forth2012/double/d-greater-zero.frt8
1 files changed, 8 insertions, 0 deletions
diff --git a/amforth-6.5/common/lib/forth2012/double/d-greater-zero.frt b/amforth-6.5/common/lib/forth2012/double/d-greater-zero.frt
new file mode 100644
index 0000000..3628320
--- /dev/null
+++ b/amforth-6.5/common/lib/forth2012/double/d-greater-zero.frt
@@ -0,0 +1,8 @@
+
+\ #require d-less-zero.frt
+
+: d0> ( d -- f)
+ 2dup or >r \ not equal zero
+ d0< 0= r> and \ and not less zero
+ 0= 0= \ normalize to 0/-1 flag
+;