We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setindex!
MWE
julia> a = [1:7;]; julia> a[Base.IdentityUnitRange(3:4)] = 2:3 2:3 julia> a[Base.IdentityUnitRange(3:4)] .= 2:3 ERROR: DimensionMismatch: array could not be broadcast to match destination Stacktrace: [1] check_broadcast_shape @ ./broadcast.jl:540 [inlined] [2] check_broadcast_axes @ ./broadcast.jl:543 [inlined] [3] instantiate @ ./broadcast.jl:284 [inlined] [4] materialize! @ ./broadcast.jl:871 [inlined] [5] materialize!(dest::SubArray{Int64, 1, Vector{Int64}, Tuple{Base.IdentityUnitRange{UnitRange{Int64}}}, true}, bc::Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{1}, Nothing, typeof(identity), Tuple{UnitRange{Int64}}}) @ Base.Broadcast ./broadcast.jl:868 [6] top-level scope @ REPL[82]:1
Ideally, these two should be equivalent, and the setindex! should really only work if the RHS has the same indices.
The text was updated successfully, but these errors were encountered:
vcat
No branches or pull requests
MWE
Ideally, these two should be equivalent, and the
setindex!
should really only work if the RHS has the same indices.The text was updated successfully, but these errors were encountered: