    # File lib/action_view/helpers/number_helper.rb, line 196
          def number_with_precision(number, *args)
            options = args.extract_options!
            options.symbolize_keys!

            defaults           = I18n.translate('number.format''number.format', :locale => options[:locale], :raise => true) rescue {}
            precision_defaults = I18n.translate('number.precision.format''number.precision.format', :locale => options[:locale],
                                                                            :raise => true) rescue {}
            defaults           = defaults.merge(precision_defaults)

            unless args.empty?
              ActiveSupport::Deprecation.warn('number_with_precision takes an option hash ' +
                'instead of a separate precision argument.', caller)
              precision = args[0] || defaults[:precision]
            end

            precision ||= (options[:precision] || defaults[:precision])
            separator ||= (options[:separator] || defaults[:separator])
            delimiter ||= (options[:delimiter] || defaults[:delimiter])

            begin
              rounded_number = (Float(number) * (10 ** precision)).round.to_f / 10 ** precision
              number_with_delimiter("%01.#{precision}f" % rounded_number,
                :separator => separator,
                :delimiter => delimiter)
            rescue
              number
            end
          end