From a3b533967d40b855fd84585e0ae6454ecc6e267a Mon Sep 17 00:00:00 2001 From: Moritz Carmesin Date: Thu, 16 Oct 2025 15:53:48 +0200 Subject: [PATCH] fix eachindex for loop --- src/SparseBandedMatrices.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SparseBandedMatrices.jl b/src/SparseBandedMatrices.jl index b77da73..3f6d89a 100644 --- a/src/SparseBandedMatrices.jl +++ b/src/SparseBandedMatrices.jl @@ -76,7 +76,7 @@ function Base.setindex!(M :: SparseBandedMatrix{T}, val, i :: Int, j :: Int, I : insert!(M.indices, ind, wanted_ind) insert!(M.diags, ind, diagvals isa Vector{T} ? diagvals : convert(Vector{T}, diagvals)::Vector{T}) else - for i in 1 : eachindex(diagvals) + for i in eachindex(diagvals) M.diags[ind][i] = diagvals[i] isa T ? diagvals[i] : convert(T, diagvals[i])::T end end