Skip to content

Commit 8845750

Browse files
committed
Remove wrappertype
1 parent 7d34ec6 commit 8845750

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/adjtrans.jl

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -332,10 +332,6 @@ wrapperop(::Transpose) = transpose
332332
_wrapperop(x) = wrapperop(x)
333333
_wrapperop(::Adjoint{<:Real}) = transpose
334334

335-
# equivalent to wrapperop, but returns the type of the wrapper
336-
wrappertype(::Adjoint) = Adjoint
337-
wrappertype(::Transpose) = Transpose
338-
339335
# the following fallbacks can be removed if Adjoint/Transpose are restricted to AbstractVecOrMat
340336
size(A::AdjOrTrans) = reverse(size(A.parent))
341337
axes(A::AdjOrTrans) = reverse(axes(A.parent))
@@ -395,7 +391,7 @@ similar(A::AdjOrTrans, ::Type{T}) where {T} = similar(A.parent, T, axes(A))
395391
similar(A::AdjOrTrans, ::Type{T}, dims::Dims{N}) where {T,N} = similar(A.parent, T, dims)
396392

397393
# AbstractMatrix{T} constructor for adjtrans vector: preserve wrapped type
398-
AbstractMatrix{T}(A::AdjOrTransAbsVec) where {T} = wrappertype(A)(AbstractVector{T}(A.parent))
394+
AbstractMatrix{T}(A::AdjOrTransAbsVec) where {T} = wrapperop(A)(AbstractVector{T}(A.parent))
399395

400396
# sundry basic definitions
401397
parent(A::AdjOrTrans) = A.parent

0 commit comments

Comments
 (0)