Skip to content

Commit 5b9b492

Browse files
abstractsparsematrix fill!
1 parent 3470ea9 commit 5b9b492

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/factorization.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ end
237237
# Try to never use it.
238238
function init_cacheval(alg::Union{QRFactorization,SVDFactorization,GenericFactorization}, A, b, u, Pl, Pr, maxiters, abstol, reltol, verbose)
239239
newA = copy(convert(AbstractMatrix,A))
240-
if newA isa SparseMatrixCSC
240+
if newA isa AbstractSparseMatrix
241241
fill!(nonzeros(newA),true)
242242
else
243243
fill!(newA,true)
@@ -248,7 +248,7 @@ end
248248
# Ambiguity handling dispatch
249249
function init_cacheval(alg::Union{QRFactorization,SVDFactorization}, A::StridedMatrix{<:LinearAlgebra.BlasFloat}, b, u, Pl, Pr, maxiters, abstol, reltol, verbose)
250250
newA = copy(convert(AbstractMatrix,A))
251-
if newA isa SparseMatrixCSC
251+
if newA isa AbstractSparseMatrix
252252
fill!(nonzeros(newA),true)
253253
else
254254
fill!(newA,true)

0 commit comments

Comments
 (0)