Skip to content

Commit 9e166d7

Browse files
committed
Deleted rrule for constructor. Fixes #67
1 parent 43a398e commit 9e166d7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "ComponentArrays"
22
uuid = "b0b7db55-cfe3-40fc-9ded-d10e2dbeff66"
33
authors = ["Jonnie Diegelman <47193959+jonniedie@users.noreply.github.com>"]
4-
version = "0.8.20"
4+
version = "0.8.21"
55

66
[deps]
77
ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9"

src/if_required/chainrulescore.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ function ChainRulesCore.rrule(::typeof(getproperty), x::ComponentArray, ::Val{s}
1515
return getproperty(x, s), getproperty_adjoint
1616
end
1717

18-
# ChainRulesCore.frule(::typeof(getdata), x::ComponentArray) = getdata(x), Δ->ComponentArray(Δ, getaxes(x))
1918
ChainRulesCore.rrule(::typeof(getdata), x::ComponentArray) = getdata(x), Δ->ComponentArray(Δ, getaxes(x))
2019

2120
ChainRulesCore.rrule(::typeof(getaxes), x::ComponentArray) = getaxes(x), Δ->ComponentArray(getdata(x), Δ)
2221

23-
ChainRulesCore.rrule(::typeof(ComponentArray), data, axes) = ComponentArray(data, axes), Δ->(getdata(Δ), getaxes(Δ))
22+
# This won't work because typeof(ComponentArray) is a UnionAll. Do we even need it, though?
23+
# ChainRulesCore.rrule(::typeof(ComponntArray), data, axes) = ComponentArray(data, axes), Δ->(getdata(Δ), getaxes(Δ))

0 commit comments

Comments
 (0)