lib/instructions/conversion/bool_from_int.rb in nudge-0.2.6 vs lib/instructions/conversion/bool_from_int.rb in nudge-0.2.7
- old
+ new
@@ -1,4 +1,13 @@
+# pops the top +:int+ item;
+# pushes a new +:bool+ item,
+# with value +false+ when the +:int+ is 0, otherwise +true
+#
+# *needs:* 1 +:int+
+#
+# *pushes:* 1 +:bool+
+#
+
class BoolFromIntInstruction < Instruction
def preconditions?
needs :int, 1
end
def setup