From e94766eb87737e334bbaa2b334bf3d2bf2ff4968 Mon Sep 17 00:00:00 2001 From: Simon Byrne Date: Wed, 4 May 2022 14:44:18 -0700 Subject: [PATCH 1/2] fix JET tests on nightly --- test/DataLayouts/data1d.jl | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/test/DataLayouts/data1d.jl b/test/DataLayouts/data1d.jl index 64509b5ebd..ba66c3a5cb 100644 --- a/test/DataLayouts/data1d.jl +++ b/test/DataLayouts/data1d.jl @@ -113,8 +113,7 @@ end # property access @test_opt getproperty(data1, :a) # test map as proxy for broadcast - @test_opt map(f, data1, data2) - @test_opt mapreduce(f, +, data1, data2) + @test_opt broadcast(f, dl1, dl2) end end end From dd13025bcd98bc5f0a70195271fd81e6600a4abd Mon Sep 17 00:00:00 2001 From: Simon Byrne Date: Thu, 5 May 2022 16:16:14 -0700 Subject: [PATCH 2/2] add extra method --- src/Geometry/coordinates.jl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Geometry/coordinates.jl b/src/Geometry/coordinates.jl index 768caa96b3..338e71d13b 100644 --- a/src/Geometry/coordinates.jl +++ b/src/Geometry/coordinates.jl @@ -186,6 +186,9 @@ Base.:(*)(x::Number, p::AbstractPoint) = p * x Base.:(/)(p::T, x::Number) where {T <: AbstractPoint} = unionalltype(T)((components(p) / x)...) +Base.LinRange(start::T, stop::T, length::Integer) where {T <: Abstract1DPoint} = + Base.LinRange{T}(start, stop, length) + # we add our own method to this so that `BigFloat` coordinate ranges are computed accurately. function Base.lerpi( j::Integer,