code cleanup by @vipulnsward [GH fixes #267]
* lib/cgi/core.rb: change each to each_value * ext/bigdecimal/lib/bigdecimal/{jacobian,math}.rb: remove unused variables from bigdecimal lib git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39992 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1950c1ce6c
commit
0cfc4866d4
@ -51,7 +51,6 @@ module Jacobian
|
|||||||
dx = fx[i].abs/ratio if isEqual(dx,f.zero,f.zero,f.eps)
|
dx = fx[i].abs/ratio if isEqual(dx,f.zero,f.zero,f.eps)
|
||||||
dx = f.one/f.ten if isEqual(dx,f.zero,f.zero,f.eps)
|
dx = f.one/f.ten if isEqual(dx,f.zero,f.zero,f.eps)
|
||||||
until ok>0 do
|
until ok>0 do
|
||||||
s = f.zero
|
|
||||||
deriv = []
|
deriv = []
|
||||||
nRetry += 1
|
nRetry += 1
|
||||||
if nRetry > 100
|
if nRetry > 100
|
||||||
|
@ -159,7 +159,6 @@ module BigMath
|
|||||||
|
|
||||||
d = one
|
d = one
|
||||||
k = one
|
k = one
|
||||||
w = one
|
|
||||||
t = BigDecimal("-80")
|
t = BigDecimal("-80")
|
||||||
while d.nonzero? && ((m = n - (pi.exponent - d.exponent).abs) > 0)
|
while d.nonzero? && ((m = n - (pi.exponent - d.exponent).abs) > 0)
|
||||||
m = BigDecimal.double_fig if m < BigDecimal.double_fig
|
m = BigDecimal.double_fig if m < BigDecimal.double_fig
|
||||||
@ -171,7 +170,6 @@ module BigMath
|
|||||||
|
|
||||||
d = one
|
d = one
|
||||||
k = one
|
k = one
|
||||||
w = one
|
|
||||||
t = BigDecimal("956")
|
t = BigDecimal("956")
|
||||||
while d.nonzero? && ((m = n - (pi.exponent - d.exponent).abs) > 0)
|
while d.nonzero? && ((m = n - (pi.exponent - d.exponent).abs) > 0)
|
||||||
m = BigDecimal.double_fig if m < BigDecimal.double_fig
|
m = BigDecimal.double_fig if m < BigDecimal.double_fig
|
||||||
|
@ -238,7 +238,7 @@ class CGI
|
|||||||
arr.each {|c| buf << "Set-Cookie: #{c}#{EOL}" }
|
arr.each {|c| buf << "Set-Cookie: #{c}#{EOL}" }
|
||||||
when Hash
|
when Hash
|
||||||
hash = cookie
|
hash = cookie
|
||||||
hash.each {|name, c| buf << "Set-Cookie: #{c}#{EOL}" }
|
hash.each_value {|c| buf << "Set-Cookie: #{c}#{EOL}" }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
if @output_cookies
|
if @output_cookies
|
||||||
|
Loading…
x
Reference in New Issue
Block a user