Skip to content

Commit 38f0133

Browse files
committed
bigdecimal/math.rb: error message in BigMath#PI
* ext/bigdecimal/lib/bigdecimal/math.rb (BigMath#PI): change error message about zero or negative precision for clarity and consistency with other methods. [GH-644] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46600 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
1 parent 8b76d21 commit 38f0133

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

ChangeLog

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
Sat Jun 28 20:29:03 2014 Simon Baird <[email protected]>
2+
3+
* ext/bigdecimal/lib/bigdecimal/math.rb (BigMath#PI): change error
4+
message about zero or negative precision for clarity and
5+
consistency with other methods. [GH-644]
6+
17
Sat Jun 28 15:32:57 2014 Tanaka Akira <[email protected]>
28

39
* lib/webrick/utils.rb (create_listeners): Close socket objects.

ext/bigdecimal/lib/bigdecimal/math.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ def atan(x, prec)
180180
# #=> "0.3141592653589793238462643388813853786957412E1"
181181
#
182182
def PI(prec)
183-
raise ArgumentError, "Zero or negative argument for PI" if prec <= 0
183+
raise ArgumentError, "Zero or negative precision for PI" if prec <= 0
184184
n = prec + BigDecimal.double_fig
185185
zero = BigDecimal("0")
186186
one = BigDecimal("1")

0 commit comments

Comments
 (0)