diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-06-29 21:25:03 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-06-29 21:25:03 +0000 |
commit | eaa572e57d1a21892e57f7e451cb991fab32b2d2 (patch) | |
tree | 43107d351095da4a3bbb1afa67cf0169106db74b /lib | |
parent | be9d096cc9f6b7ca277123ba351f84f10be3458e (diff) | |
download | ruby-eaa572e57d1a21892e57f7e451cb991fab32b2d2.tar.gz |
* lib/cmath.rb (CMath.log): second argument: b can be nil.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
-rw-r--r-- | lib/cmath.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/cmath.rb b/lib/cmath.rb index 74ef41de72..eef1134ef3 100644 --- a/lib/cmath.rb +++ b/lib/cmath.rb @@ -71,7 +71,7 @@ module CMath def log(*args) begin z, b = args - unless b.kind_of?(Numeric) + unless b.nil? || b.kind_of?(Numeric) raise TypeError, "Numeric Number required" end if z.real? and z >= 0 and (b.nil? or b >= 0) |