rails/rails — pull request #5939 by gazay (2012-04-23 16:52:00+00:00)
Title: Nice logic for deep_dup in rails

I had several problems with deep_dup in rails and here is my proposition to improve logic of Hash#deep_dup and expand it from hash to all objects.
For example, the following cases will be affected:

```ruby
{ :a => 1, { :b => [1, 2] } }.deep_dup
[1, [3, 4]].deep_dup
[1, { :a => 2 } ].deep_dup
```
and more complicated with combination of all listed above.