1
0
mirror of https://github.com/kalmarek/Groups.jl.git synced 2024-12-12 15:16:27 +01:00

parent_type dispatches after Type of element

This commit is contained in:
kalmar 2017-07-23 17:01:11 +02:00
parent 8a8d2237c5
commit 166c4c217b

View File

@ -51,7 +51,7 @@ end
elem_type{T<:Group}(G::WreathProduct{T}) = WreathProductElem{elem_type(T)} elem_type{T<:Group}(G::WreathProduct{T}) = WreathProductElem{elem_type(T)}
parent_type{T<:GroupElem}(::WreathProductElem{T}) = parent_type{T<:GroupElem}(::Type{WreathProductElem{T}}) =
WreathProduct{parent_type(T)} WreathProduct{parent_type(T)}
parent(g::WreathProductElem) = WreathProduct(parent(g.n[1]), parent(g.p)) parent(g::WreathProductElem) = WreathProduct(parent(g.n[1]), parent(g.p))