aboutsummaryrefslogtreecommitdiffstats
path: root/lib/benchmark.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/benchmark.rb')
-rw-r--r--lib/benchmark.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/benchmark.rb b/lib/benchmark.rb
index 16c4cb611a..b664841fe6 100644
--- a/lib/benchmark.rb
+++ b/lib/benchmark.rb
@@ -450,11 +450,11 @@ module Benchmark
STDOUT.sync = sync
end
- def bm(label_width = 0, *labels, &blk)
- benchmark(" "*label_width + CAPTION, label_width, FMTSTR, *labels, &blk)
+ def bm(label_width = 0, *labels)
+ benchmark(" "*label_width + CAPTION, label_width, FMTSTR, *labels){|*x|yield *x}
end
- def bmbm(width = 0, &blk)
+ def bmbm(width = 0)
job = Job.new(width)
yield(job)
width = job.width