diff --git a/Project.toml b/Project.toml index 8ba52ab..1af895b 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "LabelledArrays" uuid = "2ee39098-c373-598a-b85f-a56591580800" authors = ["Chris Rackauckas "] -version = "1.2.2" +version = "1.3.0" [deps] ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9" diff --git a/src/slarray.jl b/src/slarray.jl index 415d58e..27fe2cf 100644 --- a/src/slarray.jl +++ b/src/slarray.jl @@ -28,6 +28,8 @@ function Base.convert(::Type{NamedTuple}, x::SLArray{S,T,N,L,Syms}) where {S,T,N end Base.keys(x::SLArray{S,T,N,L,Syms}) where {S,T,N,L,Syms} = Syms +StaticArrays.similar_type(::Type{SLArray{S,T,N,L,Syms}},T2,::Size{S}) where {S,T,N,L,Syms} = SLArray{S,T2,N,L,Syms} + ## Named tuple to SLArray #= 1. `SLArray{Tuple{2,2}}((a=1, b=2, c=3, d=4))` (need to specify size)