diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-04-30 13:04:57 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-04-30 13:04:57 +0000 |
commit | e31f9b0aff2329544ce0798cccf34d381e34aa8a (patch) | |
tree | 00863acf4e045af384e9f60ff0130d40a0db0a58 | |
parent | bf4a14a274fbcc02356336449c52d3553938014a (diff) |
merge revision(s) 67467: [Backport #15756]
range.c: force hash values fixable
* range.c (method_hash): force hash values fixable on LLP64
environment. [ruby-core:92191] [Bug #15756]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@67706 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | proc.c | 2 | ||||
-rw-r--r-- | test/ruby/test_method.rb | 1 | ||||
-rw-r--r-- | version.h | 2 |
3 files changed, 3 insertions, 2 deletions
@@ -1550,7 +1550,7 @@ method_hash(VALUE method) hash = rb_hash_method_entry(hash, m->me); hash = rb_hash_end(hash); - return INT2FIX(hash); + return ST2FIX(hash); } /* diff --git a/test/ruby/test_method.rb b/test/ruby/test_method.rb index fe0171dd57..cb68b2eca9 100644 --- a/test/ruby/test_method.rb +++ b/test/ruby/test_method.rb @@ -197,6 +197,7 @@ class TestMethod < Test::Unit::TestCase def o.foo; end assert_kind_of(Integer, o.method(:foo).hash) assert_equal(Array.instance_method(:map).hash, Array.instance_method(:collect).hash) + assert_kind_of(String, o.method(:foo).hash.to_s) end def test_owner @@ -1,6 +1,6 @@ #define RUBY_VERSION "2.5.6" #define RUBY_RELEASE_DATE "2019-04-30" -#define RUBY_PATCHLEVEL 163 +#define RUBY_PATCHLEVEL 164 #define RUBY_RELEASE_YEAR 2019 #define RUBY_RELEASE_MONTH 4 |