From 27174800d460c9aa7fac49d90428a6cb01f2d66c Mon Sep 17 00:00:00 2001 From: tadf Date: Sun, 7 Jun 2009 13:46:56 +0000 Subject: * lib/cmath.rb (log): avoided redundant expression. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23644 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/cmath.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/cmath.rb b/lib/cmath.rb index 95a30c336b..5b261ed6a8 100644 --- a/lib/cmath.rb +++ b/lib/cmath.rb @@ -38,8 +38,7 @@ module CMath if z.real? and z >= 0 and (b.nil? or b >= 0) log!(*args) else - r, theta = z.polar - a = Complex(log!(r.abs), theta) + a = Complex(log!(z.abs), z.arg) if b a /= log(b) end -- cgit v1.2.3