@@ -19,7 +19,7 @@ function _make_jvp_call(fdm, f, y, xs, ẋs, ignores)
1919 f2 = _wrap_function (f, xs, ignores)
2020
2121 ignores = collect (ignores)
22- all (ignores) && return ntuple (_ -> nothing , length (xs))
22+ all (ignores) && return ntuple (_ -> NoTangent () , length (xs))
2323 sigargs = zip (xs[.! ignores], ẋs[.! ignores])
2424 return _maybe_fix_to_composite (y, jvp (fdm, f2, sigargs... ))
2525end
@@ -35,7 +35,7 @@ Call `FiniteDifferences.j′vp`, with the option to ignore certain `xs`.
3535- `ȳ`: The adjoint w.r.t. output of `f`.
3636- `xs`: Inputs to `f`, such that `y = f(xs...)`.
3737- `ignores`: Collection of `Bool`s, the same length as `xs`.
38- If `ignores[i] === true`, then `xs[i]` is ignored; `∂xs[i] === nothing `.
38+ If `ignores[i] === true`, then `xs[i]` is ignored; `∂xs[i] === NoTangent() `.
3939
4040# Returns
4141- `∂xs::Tuple`: Derivatives estimated by finite differencing.
@@ -44,7 +44,7 @@ function _make_j′vp_call(fdm, f, ȳ, xs, ignores)
4444 f2 = _wrap_function (f, xs, ignores)
4545
4646 ignores = collect (ignores)
47- args = Any[nothing for _ in 1 : length (xs)]
47+ args = Any[NoTangent () for _ in 1 : length (xs)]
4848 all (ignores) && return (args... ,)
4949 sigargs = xs[.! ignores]
5050 arginds = (1 : length (xs))[.! ignores]
@@ -66,7 +66,7 @@ Return a new version of `f`, `fnew`, that ignores some of the arguments `xs`.
6666- `f`: The function to be wrapped.
6767- `xs`: Inputs to `f`, such that `y = f(xs...)`.
6868- `ignores`: Collection of `Bool`s, the same length as `xs`.
69- If `ignores[i] === true`, then `xs[i]` is ignored; `∂xs[i] === nothing `.
69+ If `ignores[i] === true`, then `xs[i]` is ignored; `∂xs[i] === NoTangent() `.
7070"""
7171function _wrap_function (f, xs, ignores)
7272 function fnew (sigargs... )
0 commit comments