From d0857ee84383bd30ec2181a4a9f2bd4c8510f1c6 Mon Sep 17 00:00:00 2001 From: Sheehan Olver Date: Mon, 19 Aug 2019 11:10:05 +0100 Subject: [PATCH] update for latest LazyArrays (#14) * update for latest LazyArrays * v0.1.2 * Don't test on 0.7 --- .travis.yml | 1 - Project.toml | 8 ++++---- appveyor.yml | 1 - src/InfiniteArrays.jl | 21 ++++++--------------- 4 files changed, 10 insertions(+), 21 deletions(-) diff --git a/.travis.yml b/.travis.yml index b714600..cfd0e1a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,6 @@ os: - linux - osx julia: - - 0.7 - 1.0 - 1.1 - 1.2 diff --git a/Project.toml b/Project.toml index 1db53ce..78ce64f 100644 --- a/Project.toml +++ b/Project.toml @@ -1,6 +1,6 @@ name = "InfiniteArrays" uuid = "4858937d-0d70-526a-a4dd-2d5cb5dd786c" -version = "0.1.1" +version = "0.1.2" [deps] DSP = "717857b8-e6f2-59f4-9121-6e50c889abd2" @@ -12,7 +12,7 @@ Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [compat] -DSP = "≥ 0.5.1" +DSP = "0.5.1" FillArrays = "0.6" -LazyArrays = "0.9" -julia = "0.7, 1" +LazyArrays = "0.10" +julia = "1" diff --git a/appveyor.yml b/appveyor.yml index 23fca43..ff26695 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,6 +1,5 @@ environment: matrix: - - julia_version: 0.7 - julia_version: 1 - julia_version: 1.1 - julia_version: 1.2 diff --git a/src/InfiniteArrays.jl b/src/InfiniteArrays.jl index 0ebb925..7560d06 100644 --- a/src/InfiniteArrays.jl +++ b/src/InfiniteArrays.jl @@ -34,8 +34,8 @@ import LinearAlgebra: BlasInt, BlasFloat, norm, diag, diagm, ishermitian, issymm import Statistics: mean, median import FillArrays: AbstractFill, getindex_value -import LazyArrays: LazyArrayStyle, _materialize, ArrayMulArray, AbstractBandedLayout, - ZerosLayout, VcatLayout, MatMulVec, @lazymul +import LazyArrays: LazyArrayStyle, _materialize, AbstractBandedLayout, + ZerosLayout, VcatLayout, @lazymul, mulapplystyle import DSP: conv @@ -93,18 +93,9 @@ UnitRange{T}(start::Integer, ::Infinity) where T<:Real = InfUnitRange{T}(start) Int(::Infinity) = ∞ # stay lazy if infinite -_materialize(M::ArrayMulArray, ::Tuple{<:OneToInf}) = ApplyArray(M) -_materialize(M::ArrayMulArray, ::Tuple{<:OneToInf,<:OneToInf}) = ApplyArray(M) -_materialize(M::ArrayMulArray, ::Tuple{<:OneToInf,<:OneTo}) = ApplyArray(M) -_materialize(M::ArrayMulArray, ::Tuple{<:OneTo,<:OneToInf}) = ApplyArray(M) - -_materialize(M::Mul{<:Tuple,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneToInf}) = ApplyArray(M) -_materialize(M::Mul{<:Tuple,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneToInf,<:OneToInf}) = ApplyArray(M) -_materialize(M::Mul{<:Tuple,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneToInf,<:OneTo}) = ApplyArray(M) -_materialize(M::Mul{<:Tuple,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneTo,<:OneToInf}) = ApplyArray(M) - -_materialize(M::MatMulVec{<:AbstractBandedLayout,<:VcatLayout{<:Tuple{<:Any,ZerosLayout}}}, ::Tuple{<:OneToInf}) = - copyto!(similar(M), M) - +_materialize(M::Mul{<:Any,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneToInf,<:OneToInf}) = ApplyArray(M) +_materialize(M::Mul{<:Any,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneToInf}) = ApplyArray(M) +_materialize(M::Mul{<:Any,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneToInf,<:OneTo}) = ApplyArray(M) +_materialize(M::Mul{<:Any,<:Tuple{Vararg{<:AbstractArray}}}, ::Tuple{<:OneTo,<:OneToInf}) = ApplyArray(M) end # module