summaryrefslogtreecommitdiff
path: root/compar.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-01-17 16:00:11 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-01-17 16:00:11 +0000
commit636f19193362cd989758044ab6684adce90cf8b2 (patch)
tree96a8c2032332400bb1ff4ffb19ea09d790977c71 /compar.c
parent38921417228bcf683ed5e9aee12765a1dc19be0c (diff)
merge revision(s) 49224,49234,49235: [Backport #10711]
* numeric.c (bit_coerce): use original value for error message [ruby-core:67405] [Bug #10711] * test/ruby/test_numeric.rb (test_coerce): check error message git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@49313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'compar.c')
-rw-r--r--compar.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/compar.c b/compar.c
index 81dff38f49..3d0a3e81dc 100644
--- a/compar.c
+++ b/compar.c
@@ -20,7 +20,7 @@ rb_cmperr(VALUE x, VALUE y)
{
VALUE classname;
- if (SPECIAL_CONST_P(y)) {
+ if (SPECIAL_CONST_P(y) || BUILTIN_TYPE(y) == T_FLOAT) {
classname = rb_inspect(y);
}
else {