From e8149fbc67ff8e5624d78a982a9bac2c5370932e Mon Sep 17 00:00:00 2001 From: Robin Deits Date: Tue, 9 May 2017 15:45:07 -0400 Subject: [PATCH] use @static to silence warnings in v0.6 --- src/array_partition.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/array_partition.jl b/src/array_partition.jl index 5874e6d7..0c551d2f 100644 --- a/src/array_partition.jl +++ b/src/array_partition.jl @@ -35,7 +35,7 @@ Base.:*(A::ArrayPartition, B::Number) = ArrayPartition((x .* B for x in A.x)...) Base.:/(A::ArrayPartition, B::Number) = ArrayPartition((x ./ B for x in A.x)...) Base.:\(A::Number, B::ArrayPartition) = ArrayPartition((x ./ A for x in B.x)...) -if VERSION < v"0.6-" +@static if VERSION < v"0.6-" Base.:.+(A::ArrayPartition, B::ArrayPartition) = ArrayPartition((x .+ y for (x,y) in zip(A.x,B.x))...) Base.:.+(A::Number, B::ArrayPartition) = ArrayPartition((A .+ x for x in B.x)...) Base.:.+(A::ArrayPartition, B::Number) = ArrayPartition((B .+ x for x in A.x)...)