Skip to content

Commit c3a30b9

Browse files
committed
use Zero rather than DoesNotExist for NO_FIELDS
1 parent 6184811 commit c3a30b9

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/differentials/composite.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,4 +205,4 @@ Constant for the reverse-mode derivative with respect to a structure that has no
205205
The most notable use for this is for the reverse-mode derivative with respect to the
206206
function itself, when that function is not a closure.
207207
"""
208-
const NO_FIELDS = DoesNotExist()
208+
const NO_FIELDS = Zero()

test/differentials/composite.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,4 +155,8 @@ end
155155
@test (@allocated ChainRulesCore.elementwise_add(bk, bk)) <= 48
156156
end
157157
end
158+
159+
@testset "NO_FIELDS" begin
160+
@test NO_FIELDS === Zero()
161+
end
158162
end

0 commit comments

Comments
 (0)