From d371e3583e3b1e0692f92343017b62d2628190ff Mon Sep 17 00:00:00 2001 From: nobu Date: Thu, 19 May 2011 00:07:25 +0000 Subject: * lib: revert r31635-r31638 and untabify with expand(1). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31641 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/benchmark.rb | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'lib/benchmark.rb') diff --git a/lib/benchmark.rb b/lib/benchmark.rb index f3d1cca8f1..84ed6c77f9 100644 --- a/lib/benchmark.rb +++ b/lib/benchmark.rb @@ -520,14 +520,14 @@ module Benchmark cutime.__send__(op, x.cutime), cstime.__send__(op, x.cstime), real.__send__(op, x.real) - ) + ) else Benchmark::Tms.new(utime.__send__(op, x), stime.__send__(op, x), cutime.__send__(op, x), cstime.__send__(op, x), real.__send__(op, x) - ) + ) end end end @@ -548,13 +548,13 @@ if __FILE__ == $0 x.report("for:") {for _ in 1..n; _ = "1"; end} # Benchmark.measure x.report("times:") {n.times do ; _ = "1"; end} x.report("upto:") {1.upto(n) do ; _ = "1"; end} -end + end -benchmark do - [ - measure{for _ in 1..n; _ = "1"; end}, # Benchmark.measure - measure{n.times do ; _ = "1"; end}, - measure{1.upto(n) do ; _ = "1"; end} - ] + benchmark do + [ + measure{for _ in 1..n; _ = "1"; end}, # Benchmark.measure + measure{n.times do ; _ = "1"; end}, + measure{1.upto(n) do ; _ = "1"; end} + ] end end -- cgit v1.2.3