1
0
mirror of https://github.com/kalmarek/Groups.jl.git synced 2024-11-19 06:30:29 +01:00

deepcopy_internal override to protect ParentObject from duplication

This commit is contained in:
kalmar 2017-05-11 18:03:06 +02:00
parent a3db7ab92c
commit f9ccff01a8

View File

@ -60,7 +60,12 @@ function hash(W::GWord, h::UInt)
W.modified && reduce!(W)
return W.savedhash $ h
end
function deepcopy_internal{T<:GSymbol}(W::GWord{T}, dict::ObjectIdDict)
G = parent(W)
return G(GWord{T}(deepcopy(W.symbols)))
end
length(W::GWord) = sum([length(s) for s in W.symbols])
function free_reduce!(W::GWord)