@@ -124,16 +124,16 @@ end
124
124
Returns the parent array that type `T` wraps.
125
125
"""
126
126
parent_type (x) = parent_type (typeof (x))
127
- parent_type (:: Type{Symmetric{T,S }} ) where {T,S} = S
128
- parent_type (:: Type{<:AbstractTriangular{T,S }} ) where {T,S} = S
127
+ parent_type (@nospecialize T :: Type{<:Union{Symmetric,Hermitian }} ) = fieldtype (T, :data )
128
+ parent_type (@nospecialize T :: Type{<:Union{UpTri,LoTri }} ) = fieldtype (T, :data )
129
129
parent_type (@nospecialize T:: Type{<:PermutedDimsArray} ) = fieldtype (T, :parent )
130
130
parent_type (@nospecialize T:: Type{<:Adjoint} ) = fieldtype (T, :parent )
131
131
parent_type (@nospecialize T:: Type{<:Transpose} ) = fieldtype (T, :parent )
132
132
parent_type (@nospecialize T:: Type{<:SubArray} ) = fieldtype (T, :parent )
133
133
parent_type (@nospecialize T:: Type{<:Base.ReinterpretArray} ) = fieldtype (T, :parent )
134
134
parent_type (@nospecialize T:: Type{<:Base.ReshapedArray} ) = fieldtype (T, :parent )
135
135
parent_type (@nospecialize T:: Type{<:Union{Base.Slice,Base.IdentityUnitRange}} ) = fieldtype (T, :indices )
136
- parent_type (:: Type{Diagonal{T,V}} ) where {T,V} = V
136
+ parent_type (@nospecialize T :: Type{<: Diagonal} ) = fieldtype (T, :diag )
137
137
parent_type (T:: Type ) = T
138
138
139
139
"""
0 commit comments