Julia: vcat of range and matrix causes stack overflow

Created on 27 Jan 2018  Â·  2Comments  Â·  Source: JuliaLang/julia

julia> vcat(1:8, fill(1, (4, 1)))
ERROR: StackOverflowError:
Stacktrace:
 [1] Type at ./boot.jl:364 [inlined]
 [2] Type at ./boot.jl:378 [inlined]
 [3] fill at ./array.jl:340 [inlined]
 [4] vcat(::UnitRange{Int64}, ::Array{Int64,2}) at /Users/ericdavies/repos/juliamaster/usr/share/julia/site/v0.7/LinearAlgebra/src/uniformscaling.jl:297 (repeats 47636 times)
 [5] top-level scope

Tried it on 0.6.2 and 0.7.0-DEV.3563 with the same results.

Originally found by @spurll

arrays bug

Most helpful comment

Just submitted a fix.

All 2 comments

Found this got stack overflow, also

vcat(1:8, reshape([1, 1, 1, 1], 4, 1))

Just submitted a fix.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

StefanKarpinski picture StefanKarpinski  Â·  3Comments

ararslan picture ararslan  Â·  3Comments

yurivish picture yurivish  Â·  3Comments

felixrehren picture felixrehren  Â·  3Comments

tkoolen picture tkoolen  Â·  3Comments