From 6561b40d620b07c194212bc0ebda5ea5f6526498 Mon Sep 17 00:00:00 2001 From: Chris Rackauckas Date: Thu, 3 Sep 2020 16:34:02 -0400 Subject: [PATCH 1/2] Fix non-differentiation ruleset for keyword argument dropping I don't really know what to call this, but it fixes https://github.com/JuliaDiff/ChainRules.jl/issues/257 , whatever that is. --- Project.toml | 2 +- src/rulesets/Base/nondiff.jl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Project.toml b/Project.toml index a2db1c45a..632a6f587 100644 --- a/Project.toml +++ b/Project.toml @@ -1,6 +1,6 @@ name = "ChainRules" uuid = "082447d4-558c-5d27-93f4-14fc19e9eca2" -version = "0.7.16" +version = "0.7.17" [deps] ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" diff --git a/src/rulesets/Base/nondiff.jl b/src/rulesets/Base/nondiff.jl index 56f52f009..c318fe340 100644 --- a/src/rulesets/Base/nondiff.jl +++ b/src/rulesets/Base/nondiff.jl @@ -376,8 +376,8 @@ VERSION >= v"1.1" && @non_differentiable splitpath(::AbstractString) @non_differentiable xor(::Any, ::Any, ::Any, ::Any, ::Any) # Non-public Base -@non_differentiable Base.OneTo(::Integer) @non_differentiable Base.OneTo(::AbstractRange{<:Integer}) + @non_differentiable Base.gc_num() @non_differentiable Base.time_ns() @non_differentiable Base.typename(::Any) From 0a4b9648dbae87eab23202e44b81b3d1111d3a34 Mon Sep 17 00:00:00 2001 From: Chris Rackauckas Date: Thu, 3 Sep 2020 16:39:13 -0400 Subject: [PATCH 2/2] delete the other one since if you accidentally hit this it must be doing the same thing just on ranges. --- src/rulesets/Base/nondiff.jl | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/rulesets/Base/nondiff.jl b/src/rulesets/Base/nondiff.jl index c318fe340..ede42ac31 100644 --- a/src/rulesets/Base/nondiff.jl +++ b/src/rulesets/Base/nondiff.jl @@ -376,8 +376,6 @@ VERSION >= v"1.1" && @non_differentiable splitpath(::AbstractString) @non_differentiable xor(::Any, ::Any, ::Any, ::Any, ::Any) # Non-public Base -@non_differentiable Base.OneTo(::AbstractRange{<:Integer}) - @non_differentiable Base.gc_num() @non_differentiable Base.time_ns() @non_differentiable Base.typename(::Any)