(In the REPL) Create a 1D array of 1D arrays of Points:
julia>using GLMakie
julia> A = fill(fill(Point2f0(0,0), 2), 2)
2-element Array{Array{Point{2,Float32},1},1}:
[[0.0, 0.0], [0.0, 0.0]]
[[0.0, 0.0], [0.0, 0.0]]
Change the value of the first point in the first vector of points:
julia> A[1][1] = Point2f0(1,1)
2-element Point{2,Float32} with indices SOneTo(2):
1.0
1.0
But …
julia> A
2-element Array{Array{Point{2,Float32},1},1}:
[[1.0, 1.0], [0.0, 0.0]]
[[1.0, 1.0], [0.0, 0.0]]
… why does this re-assign the first point in every vector of points? I expect the result of the previous snippet to be
[[1.0, 1.0], [0.0, 0.0]]
[[0.0, 0.0], [0.0, 0.0]]
what am I missing???