replacing a hash with itself returns an empty hash in ruby 1.9 compatibility mode #544

Merged
merged 1 commit into from Feb 26, 2013

Projects

None yet

2 participants

@glucero
Contributor
glucero commented Feb 21, 2013

jruby (ruby 1.9 mode):

h = {:one => 1}
=> { :one => 1 }
h.replace h
=> {}

mri (1.8.7 through 2.0.0-rc2) and jruby (ruby 1.8 mode):

h = {:one => 1}
=> { :one => 1 }
h.replace h
=> { :one => 1 }

@headius
Member
headius commented Feb 26, 2013

Wow, wacky! Can you also put together a spec PR for https://github.com/rubyspec/rubyspec?

@headius headius merged commit c17ea46 into jruby:master Feb 26, 2013

1 check passed

default The Travis build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment