Browse files

Implement Function#size.

  • Loading branch information...
1 parent f1272df commit fe131bb9ef426c5fe69e50a26f9f0eab0995b30f @whitequark committed Mar 20, 2013
Showing with 4 additions and 0 deletions.
  1. +4 −0 lib/furnace/ssa/function.rb
View
4 lib/furnace/ssa/function.rb
@@ -110,6 +110,10 @@ def each(&proc)
alias each_basic_block each
+ def size
+ @basic_blocks.count
+ end
+
def include?(name)
@basic_blocks.any? { |n| n.name == name }
end

0 comments on commit fe131bb

Please sign in to comment.