Skip to content

Commit febe6e1

Browse files
authored
fix AD demos on Julia nightly (#299)
* fix AD demos on Julia nightly * bump patch version
1 parent 557a8c2 commit febe6e1

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

test/demos/forwarddiffzero.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ function define_dual_overload(sig)
3232
opT, argTs = Iterators.peel(sig.parameters)
3333
opT isa Type{<:Type} && return # not handling constructors
3434
fieldcount(opT) == 0 || return # not handling functors
35-
all(Float64 <: argT for argT in argTs) || return # only handling purely Float64 ops.
35+
all(argT isa Type && Float64 <: argT for argT in argTs) || return # only handling purely Float64 ops.
3636

3737
N = length(sig.parameters) - 1 # skip the op
3838
fdef = quote

test/demos/reversediffzero.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ function define_tracked_overload(sig)
6161
opT, argTs = Iterators.peel(sig.parameters)
6262
opT isa Type{<:Type} && return # not handling constructors
6363
fieldcount(opT) == 0 || return # not handling functors
64-
all(Float64 <: argT for argT in argTs) || return # only handling purely Float64 ops.
64+
all(argT isa Type && Float64 <: argT for argT in argTs) || return # only handling purely Float64 ops.
6565

6666
N = length(sig.parameters) - 1 # skip the op
6767
fdef = quote

0 commit comments

Comments
 (0)