Skip to content

Commit b62e257

Browse files
Force convert diagonal to real in eigen(::Hermitian) (#1280)
This matches the behavior for normal arrays
1 parent b2f2fb0 commit b62e257

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/eigen.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,9 @@ end
5757
end
5858
Sreal = real(S)
5959

60-
@inbounds a11 = convert(Sreal, A.data[1])
61-
@inbounds a22 = convert(Sreal, A.data[5])
62-
@inbounds a33 = convert(Sreal, A.data[9])
60+
@inbounds a11 = convert(Sreal, real(A.data[1]))
61+
@inbounds a22 = convert(Sreal, real(A.data[5]))
62+
@inbounds a33 = convert(Sreal, real(A.data[9]))
6363
if A.uplo == 'U'
6464
@inbounds a12 = convert(S, A.data[4])
6565
@inbounds a13 = convert(S, A.data[7])

0 commit comments

Comments
 (0)