Setindex for CartesianIndex

Perhaps we should shorten this by defining setindex on CartesianIndex, but for now

julia> I = CartesianIndex(1, 2, 3, 4, 5)
CartesianIndex(1, 2, 3, 4, 5)

julia> I = CartesianIndex(Base.setindex(Tuple(I), 50, 3))
CartesianIndex(1, 2, 50, 4, 5)
1 Like