Stack effect: ( f f -- f )
Find the logical "and" of the top two elements on the stack.
NOTE: In contrast to traditional Forth, logical "and" is used instead of bitwise "and". This choice was made because in a Forth with a floating point data stack, logical operations are more useful in combining multiplicative masks, whereas bitwise operations are at best ambiguous.
Boolean values in Haiku Forth are returned as 1 (true) or 0 (false). This is in contrast to traditional Forth in which -1 is used for true. This choice to go 1 for true was made to facilitate using boolean value as multiplicative masks. For example: x 0.5 < * . The Forth/C convention that anything non-zero is considered an alternate stand-in for true is carried over.
NOTE: In Haiku Forth (unlike Traditional Forth), all stack cells and memory locations are floating point numbers.
Examples: