lib/instructions/code/code_contains_q.rb in nudge-0.2.6 vs lib/instructions/code/code_contains_q.rb in nudge-0.2.7
- old
+ new
@@ -1,4 +1,15 @@
+# pops the top 2 item of the +:code+ stack;
+# pushes a new ValuePoint onto the +:bool+ stack, with value +true+ if the
+# second argument appears as a sub-block anywhere in the first argument
+#
+# note: order matters, and the top stack item is the second argument, the second stack item is the first
+#
+# *needs:* 2 +:code+
+#
+# *pushes:* 1 +:bool+
+#
+
class CodeContainsQInstruction < Instruction
def preconditions?
needs :code, 2
end
def setup