Created
October 7, 2009 17:48
-
-
Save sodabrew/204252 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Is there a better way to deep copy a structure in Ruby? | |
if templates.has_key?(ip) | |
# There's no deep copy in Ruby, so we do this horrific thing | |
desired_records = Marshal::load(Marshal.dump(templates[ip])) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment