Skip to content

Commit 061a541

Browse files
authored
Fix Int32 support (#37)
* Fix small bug at int32 support * Strange inference bug * Actually introduce the bug
1 parent 40d494b commit 061a541

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/aggregate.jl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,12 +97,14 @@ function aggregation(::StandardAggregation, S::SparseMatrixCSC{T,R}) where {T,R}
9797
if minimum(x) == -1
9898
mask = x .!= -1
9999
I = collect(R, 1:n)[mask]
100-
J = x[mask] + 1
100+
J = x[mask] + R(1)
101+
#J = x[mask] + 1
101102
V = ones(eltype(S), length(J))
102103
AggOp = sparse(J,I,V,N,M)
103104
else
104105
Tp = collect(R, 1:n+1)
105-
x .= x .+ 1
106+
x .= x .+ R(1)
107+
#x .= x .+ 1
106108
Tx = ones(eltype(S), length(x))
107109
AggOp = SparseMatrixCSC(N, M, Tp, x, Tx)
108110
end

0 commit comments

Comments
 (0)