Closed
Description
We currently have partial support for mutation in forwards mode, (I think)
I believe mutating arrays works, but mutating structs does not.
We need two things for this:
- MutableTangent ChainRulesCore.jl#105 a MutableTangent type
- To never automatically insert
ZeroTangent
for mutable structs, and instead us aMutableTangent
with no fields/all fields set to ZeroTangents (unless those fields themselves are mutable structs)
Mutation in forwards mode is much easier than reverse.