@@ -486,7 +486,7 @@ function toexpr(a::MakeArray, st)
486
486
end
487
487
488
488
# # Array
489
- @inline function _create_array (:: Type{<:AbstractArray } , T, :: Val{dims} , elems... ) where dims
489
+ @inline function _create_array (:: Type{<:Array } , T, :: Val{dims} , elems... ) where dims
490
490
arr = Array {T} (undef, dims)
491
491
@assert prod (dims) == nfields (elems)
492
492
@inbounds for i= 1 : prod (dims)
@@ -495,32 +495,32 @@ end
495
495
arr
496
496
end
497
497
498
- @inline function create_array (A:: Type{<:AbstractArray } , T, :: Val , d:: Val , elems... )
498
+ @inline function create_array (A:: Type{<:Array } , T, :: Val , d:: Val , elems... )
499
499
_create_array (A, T, d, elems... )
500
500
end
501
501
502
- @inline function create_array (A:: Type{<:AbstractArray } , :: Nothing , :: Val , d:: Val{dims} , elems... ) where dims
502
+ @inline function create_array (A:: Type{<:Array } , :: Nothing , :: Val , d:: Val{dims} , elems... ) where dims
503
503
T = promote_type (map (typeof, elems)... )
504
504
_create_array (A, T, d, elems... )
505
505
end
506
506
507
507
# # Vector
508
508
#
509
- @inline function create_array (:: Type{<:AbstractArray } , :: Nothing , :: Val{1} , :: Val{dims} , elems... ) where dims
509
+ @inline function create_array (:: Type{<:Array } , :: Nothing , :: Val{1} , :: Val{dims} , elems... ) where dims
510
510
[elems... ]
511
511
end
512
512
513
- @inline function create_array (:: Type{<:AbstractArray } , T, :: Val{1} , :: Val{dims} , elems... ) where dims
513
+ @inline function create_array (:: Type{<:Array } , T, :: Val{1} , :: Val{dims} , elems... ) where dims
514
514
T[elems... ]
515
515
end
516
516
517
517
# # Matrix
518
518
519
- @inline function create_array (:: Type{<:AbstractArray } , :: Nothing , :: Val{2} , :: Val{dims} , elems... ) where dims
519
+ @inline function create_array (:: Type{<:Array } , :: Nothing , :: Val{2} , :: Val{dims} , elems... ) where dims
520
520
vhcat (dims, elems... )
521
521
end
522
522
523
- @inline function create_array (:: Type{<:AbstractArray } , T, :: Val{2} , :: Val{dims} , elems... ) where dims
523
+ @inline function create_array (:: Type{<:Array } , T, :: Val{2} , :: Val{dims} , elems... ) where dims
524
524
typed_vhcat (T, dims, elems... )
525
525
end
526
526
0 commit comments