You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This macro only accepts a few functions. But if the ones it accepts aren't imported, it quietly does the wrong thing. Surely this should always make a method for ChainRulesCore.rrule:
julia>using ChainRulesCore:@opt_out
julia> ChainRulesCore.@opt_out*(::Rotation, ::Rotation)
ERROR: LoadError: Unexpected opt-out target. Exprected frule or rrule, got:*
julia> ChainRulesCore.@opt_outrrule(::typeof(*), ::Rotation, ::Rotation)
ERROR: LoadError: UndefVarError: ChainRulesCore not defined
in expression starting at REPL[3]:1
julia>using ChainRulesCore
julia> ChainRulesCore.@opt_outrrule(::typeof(*), ::Rotation, ::Rotation)
rrule (generic function with 1 method)
julia>@macroexpand ChainRulesCore.@opt_outrrule(::typeof(*), ::Rotation, ::Rotation)
quote
ChainRulesCore.no_rrule(::typeof(*), ::Rotation, ::Rotation) = ChainRulesCore.nothingrrule(::typeof(*), ::Rotation, ::Rotation) = ChainRulesCore.nothingend
The text was updated successfully, but these errors were encountered:
Yes, it would be good to fix this.
This is on me, I knew it wasn't scoping right but wanted to get it in for the 1.0 deadline so we could test it and change it is it's API was wrong.
I probably should have openned an issue about it when the original PR was merged.
This macro only accepts a few functions. But if the ones it accepts aren't imported, it quietly does the wrong thing. Surely this should always make a method for
ChainRulesCore.rrule
:The text was updated successfully, but these errors were encountered: