From b8f20498abe2692b34d5f6eddb20437fe4f0ce6d Mon Sep 17 00:00:00 2001 From: Fredrik Bagge Carlson Date: Thu, 4 Apr 2019 15:14:11 +0200 Subject: [PATCH] add undef initializer --- src/utils.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils.jl b/src/utils.jl index 32618a03..47414671 100644 --- a/src/utils.jl +++ b/src/utils.jl @@ -28,7 +28,7 @@ function recursivecopy!(b::AbstractArray{T,N},a::AbstractArray{T2,N}) where {T<: end function vecvec_to_mat(vecvec) - mat = Matrix{eltype(eltype(vecvec))}(length(vecvec),length(vecvec[1])) + mat = Matrix{eltype(eltype(vecvec))}(undef, length(vecvec),length(vecvec[1])) for i in 1:length(vecvec) mat[i,:] = vecvec[i] end