Skip to content

Commit 1d01f3d

Browse files
authored
Merge pull request #776 from christiangnrd/patch-1
Fix `UndefVarError: sparseinv not defined` test failures
2 parents e569283 + e8f01da commit 1d01f3d

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/rulesets/SparseArrays/sparsematrix.jl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,8 @@ function rrule(::typeof(findnz), v::AbstractSparseVector)
5151
end
5252

5353
if Base.USE_GPL_LIBS # Don't define rrules for sparse determinants if we don't have CHOLMOD from SuiteSparse.jl
54-
54+
using SparseInverseSubset
55+
5556
if VERSION < v"1.7"
5657
#=
5758
The method below for `logabsdet(F::UmfpackLU)` is required to calculate the (log)
@@ -82,8 +83,6 @@ if Base.USE_GPL_LIBS # Don't define rrules for sparse determinants if we don't h
8283
end
8384
return ifelse(isodd(result), -1, 1)
8485
end
85-
86-
using SparseInverseSubset
8786

8887
function LinearAlgebra.logabsdet(F::UmfpackLU{T, TI}) where {T<:Union{Float64,ComplexF64},TI<:Union{Int32, Int64}}
8988
n = checksquare(F)

0 commit comments

Comments
 (0)