ruby-changes:5615
From: shyouhei <ko1@a...>
Date: Fri, 13 Jun 2008 11:57:29 +0900 (JST)
Subject: [ruby-changes:5615] Ruby:r17121 (ruby_1_8_5): merge revision(s) 15369:
shyouhei 2008-06-13 11:57:18 +0900 (Fri, 13 Jun 2008) New Revision: 17121 Modified files: branches/ruby_1_8_5/ChangeLog branches/ruby_1_8_5/lib/benchmark.rb branches/ruby_1_8_5/version.h Log: merge revision(s) 15369: * lib/benchmark.rb (Benchmark::realtime): make Benchmark#realtime a bit faster. a patch from Alexander Dymo <dymo@u...> in [ruby-core:15337]. http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_5/lib/benchmark.rb?r1=17121&r2=17120&diff_format=u http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_5/version.h?r1=17121&r2=17120&diff_format=u http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/branches/ruby_1_8_5/ChangeLog?r1=17121&r2=17120&diff_format=u Index: ruby_1_8_5/ChangeLog =================================================================== --- ruby_1_8_5/ChangeLog (revision 17120) +++ ruby_1_8_5/ChangeLog (revision 17121) @@ -1,3 +1,9 @@ +Fri Jun 13 11:56:28 2008 Yukihiro Matsumoto <matz@r...> + + * lib/benchmark.rb (Benchmark::realtime): make Benchmark#realtime + a bit faster. a patch from Alexander Dymo <dymo@u...> in + [ruby-core:15337]. + Fri Jun 13 11:42:52 2008 Yukihiro Matsumoto <matz@r...> * io.c (rb_open_file): should check NUL in path. Index: ruby_1_8_5/version.h =================================================================== --- ruby_1_8_5/version.h (revision 17120) +++ ruby_1_8_5/version.h (revision 17121) @@ -2,7 +2,7 @@ #define RUBY_RELEASE_DATE "2008-06-13" #define RUBY_VERSION_CODE 185 #define RUBY_RELEASE_CODE 20080613 -#define RUBY_PATCHLEVEL 169 +#define RUBY_PATCHLEVEL 170 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 Index: ruby_1_8_5/lib/benchmark.rb =================================================================== --- ruby_1_8_5/lib/benchmark.rb (revision 17120) +++ ruby_1_8_5/lib/benchmark.rb (revision 17121) @@ -304,7 +304,10 @@ # Returns the elapsed real time used to execute the given block. # def realtime(&blk) # :yield: - Benchmark::measure(&blk).real + r0 = Time.now + yield + r1 = Time.now + r1.to_f - r0.to_f end -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/