diff options
author | Vasiliy Ermolovich <younash@gmail.com> | 2012-02-21 19:46:49 +0300 |
---|---|---|
committer | Vasiliy Ermolovich <younash@gmail.com> | 2012-02-21 19:54:16 +0300 |
commit | 9dd64f2e0c1b3ce85b503b0f81c50c93f89ffbcd (patch) | |
tree | ddff9c038622c0e7523f148265aab68c5d7f7099 /actionpack/Rakefile | |
parent | 67a5157974ed9809570e2b29b69b59b85a4c7c52 (diff) | |
download | rails-9dd64f2e0c1b3ce85b503b0f81c50c93f89ffbcd.tar.gz rails-9dd64f2e0c1b3ce85b503b0f81c50c93f89ffbcd.tar.bz2 rails-9dd64f2e0c1b3ce85b503b0f81c50c93f89ffbcd.zip |
refactor time_zone_options_for_select
BTW, select works quite faster then find_all:
require 'benchmark'
n = [1]*100_000_000
Benchmark.bm do |x|
x.report { n.select { |a| a > 1 } }
x.report { n.find_all { |a| a > 1 } }
end
user system total real
7.590000 0.010000 7.600000 ( 7.927171)
9.650000 0.010000 9.660000 ( 9.634406)
Diffstat (limited to 'actionpack/Rakefile')
0 files changed, 0 insertions, 0 deletions