Skip to content

Commit

Permalink
pointless optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
araujoms committed Jan 29, 2025
1 parent fcdccc4 commit 9a9e1d3
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/nonlocal.jl
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,10 @@ end
function _digits(ind; base)
N = length(base)
digits = zeros(Int, N)
@inbounds for i 1:N
digits[i] = ind % base[i]
ind = ind ÷ base[i]
i = 0
@inbounds while (ind != 0 && i N - 1)
i += 1
ind, digits[i] = divrem(ind, base[i])
end
return digits
end
Expand Down

0 comments on commit 9a9e1d3

Please sign in to comment.