1- struct QLayout <: MemoryLayout end
1+ abstract type AbstractQLayout <: MemoryLayout end
2+ struct QLayout <: AbstractQLayout end
23
34MemoryLayout (:: Type{<:AbstractQ} ) = QLayout ()
45
5- transposelayout (:: QLayout ) = QLayout ()
6+ adjointlayout (:: Type , :: AbstractQLayout ) = QLayout ()
67
78
8- copy (M:: Lmul{QLayout } ) = copyto! (similar (M), M)
9+ copy (M:: Lmul{<:AbstractQLayout } ) = copyto! (similar (M), M)
910
10- function copyto! (dest:: AbstractArray{T} , M:: Lmul{QLayout } ) where T
11+ function copyto! (dest:: AbstractArray{T} , M:: Lmul{<:AbstractQLayout } ) where T
1112 A,B = M. A,M. B
1213 if size (dest,1 ) == size (B,1 )
1314 copyto! (dest, B)
@@ -18,13 +19,15 @@ function copyto!(dest::AbstractArray{T}, M::Lmul{QLayout}) where T
1819 materialize! (Lmul (A,dest))
1920end
2021
21- function copyto! (dest:: AbstractArray , M:: Ldiv{QLayout } )
22+ function copyto! (dest:: AbstractArray , M:: Ldiv{<:AbstractQLayout } )
2223 A,B = M. A,M. B
2324 copyto! (dest, B)
2425 materialize! (Ldiv (A,dest))
2526end
2627
27- materialize! (M:: Ldiv{QLayout} ) = materialize! (Lmul (M. A' ,M. B))
28+ materialize! (M:: Lmul{LAY} ) where LAY<: AbstractQLayout = error (" Overload materialize!(::Lmul{$(LAY) })" )
29+ materialize! (M:: Rmul{LAY} ) where LAY<: AbstractQLayout = error (" Overload materialize!(::Lmul{$(LAY) })" )
30+ materialize! (M:: Ldiv{<:AbstractQLayout} ) = materialize! (Lmul (M. A' ,M. B))
2831
2932_qr (layout, axes, A; kwds... ) = Base. invoke (qr, Tuple{AbstractMatrix{eltype (A)}}, A; kwds... )
3033_qr (layout, axes, A, pivot:: P ; kwds... ) where P = Base. invoke (qr, Tuple{AbstractMatrix{eltype (A)},P}, A, pivot; kwds... )
0 commit comments