lib/deep_copy.rb in taskjuggler-0.0.6 vs lib/deep_copy.rb in taskjuggler-0.0.7
- old
+ new
@@ -35,10 +35,10 @@
def deep_clone
# We can't clone frozen objects. So just return a reference to them.
# Built-in classed can't be cloned either. The check below is probably
# cheaper than the frequent (hiddent) exceptions from those objects.
return self if frozen? || nil? || is_a?(Fixnum) || is_a?(Float) ||
- is_a?(TrueClass) || is_a?(FalseClass)
+ is_a?(TrueClass) || is_a?(FalseClass) || is_a?(Symbol)
# In case we have loops in our graph, we return references, not
# deep-copied objects.
if RUBY_VERSION < '1.9.0'
return @clonedObject if instance_variables.include?('@clonedObject')