Skip to content

Commit 43bb1f5

Browse files
committed
replace nextind with i+1
1 parent c0f9a63 commit 43bb1f5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

base/abstractarray.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -894,10 +894,10 @@ function copyto!(dest::AbstractArray, src)
894894
if haslength(src)
895895
length(dest) < length(src) &&
896896
throw(ArgumentError("destination has fewer elements than required"))
897-
I = firstindex(dest)
897+
i = Int(firstindex(dest))
898898
@inbounds for x in src
899-
dest[I] = x
900-
I = nextind(dest, I)
899+
dest[i] = x
900+
i += 1
901901
end
902902
else
903903
destiter = eachindex(dest)

0 commit comments

Comments
 (0)