提交 ebe4fa5f 编写于 作者: X Xavier Noria

move the conditional definition of Float#round down

Rails 3 cherry-picks as little as possible from Active Support. In particular
the framework requires the files where extensions are exactly defined, rather
than convenience entry points like float.rb and friends. Because of that, it
is better to define conditionally rather than require conditionally.
上级 32b5c4b7
require 'active_support/core_ext/float/rounding' if RUBY_VERSION < '1.9'
require 'active_support/core_ext/float/rounding'
......@@ -16,4 +16,4 @@ def round(precision = nil)
precisionless_round
end
end
end
end if RUBY_VERSION < '1.9'
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册