3 ms·
Yes, and it is a perfectly fine feature when applied correctly. It would be incorrect to assume that an `AbstractArray` starts at `1` or `0` which is why the up
by markkitti 4y ago
Yes, and it is a perfectly fine feature when applied correctly. It would be incorrect to assume that an `AbstractArray` starts at `1` or `0` which is why the updated example now correctly uses `eachindex`:
https://docs.julialang.org/en/v1/devdocs/boundscheck/#Eliding-bounds-checks https://docs.julialang.org/en/v1/devdocs/boundscheck/#Elidin...
If you want to assume that an array starts at `1` one needs to require an `Array` rather than an `AbstractArray`.