File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -149,9 +149,11 @@ struct NoSuperType end
149149
150150 @testset " Base: Tuple" begin
151151 pt1 = ProjectTo ((1.0 ,))
152- @test @inferred (pt1 ((1 + im,))) == Tangent {Tuple{Float64}} (1.0 ,)
153- @test @inferred (pt1 (pt1 ((1 ,)))) == pt1 (pt1 ((1 ,))) # accepts correct Tangent
154- @test @inferred (pt1 (Tangent {Any} (1 ))) == pt1 ((1 ,)) # accepts Tangent{Any}
152+ if VERSION >= v " 1.6"
153+ @test @inferred (pt1 ((1 + im,))) == Tangent {Tuple{Float64}} (1.0 )
154+ @test @inferred (pt1 (pt1 ((1 ,)))) == pt1 (pt1 ((1 ,))) # accepts correct Tangent
155+ @test @inferred (pt1 (Tangent {Any} (1 ))) == pt1 ((1 ,)) # accepts Tangent{Any}
156+ end
155157 @test pt1 ([1 ,]) == Tangent {Tuple{Float64}} (1.0 ,) # accepts Vector
156158 @test @inferred (pt1 (NoTangent ())) === NoTangent ()
157159 @test @inferred (pt1 (ZeroTangent ())) === ZeroTangent ()
You can’t perform that action at this time.
0 commit comments