Skip to content

Commit 4e3164a

Browse files
authored
force sym/herm back to return Matrix (1.6 inference fix) (#393)
* force sym/herm back to return Matrix * =bump version
1 parent 67c106f commit 4e3164a

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,6 +1,6 @@
11
name = "ChainRules"
22
uuid = "082447d4-558c-5d27-93f4-14fc19e9eca2"
3-
version = "0.7.55"
3+
version = "0.7.56"
44

55
[deps]
66
ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"

src/rulesets/LinearAlgebra/symmetric.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ end
6868
end
6969
end
7070
L, U, D = LowerTriangular(ΔΩ), UpperTriangular(ΔΩ), Diagonal(ΔΩ)
71-
return uplo === :U ? U .+ transpose(L) - D : L .+ transpose(U) - D
71+
return Matrix(uplo === :U ? U .+ transpose(L) - D : L .+ transpose(U) - D)
7272
end
7373

7474
@inline function _hermitian_back(ΔΩ, uplo::Symbol)
@@ -83,7 +83,7 @@ end
8383
end
8484
end
8585
L, U, rD = LowerTriangular(ΔΩ), UpperTriangular(ΔΩ), real.(Diagonal(ΔΩ))
86-
return uplo === :U ? U .+ L' - rD : L .+ U' - rD
86+
return Matrix(uplo === :U ? U .+ L' - rD : L .+ U' - rD)
8787
end
8888

8989
#####

0 commit comments

Comments
 (0)