Flowdock
method

deep_dup

Importance_1
Ruby on Rails latest stable (v4.1.8) - 0 notes - Class: Array
deep_dup() public

Returns a deep copy of array.

array = [1, [2, 3]]
dup   = array.deep_dup
dup[1][2] = 4

array[1][2] # => nil
dup[1][2]   # => 4
Show source
Register or log in to add new notes.