Skip to content

Commit 2ec9fda

Browse files
version gate returns
1 parent 473a9b2 commit 2ec9fda

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/forwarddiff.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,10 @@ end
113113
anyeltypedual(x::Union{ForwardDiff.AbstractConfig, Module}, counter = 0) = Any
114114
anyeltypedual(x::Type{T}, counter = 0) where {T <: ForwardDiff.AbstractConfig} = Any
115115
anyeltypedual(x::SciMLBase.RecipesBase.AbstractPlot, counter = 0) = Any
116-
anyeltypedual(x::Returns, counter = 0) = anyeltypedual(x.value, counter)
116+
117+
if VERSION >= v"1.7"
118+
anyeltypedual(x::Returns, counter = 0) = anyeltypedual(x.value, counter)
119+
end
117120

118121
if isdefined(PreallocationTools, :FixedSizeDiffCache)
119122
anyeltypedual(x::PreallocationTools.FixedSizeDiffCache, counter = 0) = Any

0 commit comments

Comments
 (0)