This code works in Julia 0.6, but not the latest Julia 0.7. Is there any alternative ways to do this?
seg = zeros(UInt32,(100,100,100))
seg[48:52,48:52, 1:end ] = one(UInt32)
I got errors as follows:
ERROR: MethodError: no method matching setindex_shape_check(::UInt32, ::Int64, ::Int64, ::Int64)
Closest candidates are:
setindex_shape_check(::AbstractArray, ::Integer...) at indices.jl:154
setindex_shape_check(::AbstractArray{#s57,1} where #s57, ::Integer, ::Integer) at indices.jl:196
setindex_shape_check(::AbstractArray{#s57,2} where #s57, ::Integer, ::Integer) at indices.jl:200
...
Stacktrace:
[1] macro expansion at ./multidimensional.jl:641 [inlined]
[2] _unsafe_setindex!(::IndexLinear, ::Array{UInt32,3}, ::UInt32, ::UnitRange{Int64}, ::UnitRange{Int
64}, ::UnitRange{Int64}) at ./multidimensional.jl:636
[3] _setindex! at ./multidimensional.jl:631 [inlined]
[4] setindex!(::Array{UInt32,3}, ::UInt32, ::UnitRange{Int64}, ::UnitRange{Int64}, ::UnitRange{Int64}
) at ./abstractarray.jl:998
[5] top-level scope at none:0