diff --git a/lib/comfpile/core.rb b/lib/comfpile/core.rb index dd9f03c..73c28c8 100644 --- a/lib/comfpile/core.rb +++ b/lib/comfpile/core.rb @@ -89,8 +89,13 @@ module Comfpile end def processing_stack_find_next() + i = 0 @processing_stack.reverse_each do |a| - return a if a.waiting? + i += 1 + if a.waiting? + puts "DBG - Found item after #{i} checks" + return a + end end nil