Skip to content

Commit c902106

Browse files
committed
[fix] makeblascontractable should return blascontractable objects.
1 parent 390aed8 commit c902106

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/implementation/blascontract.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,9 @@ end
8484
function makeblascontractable(A, pA, TC, backend, allocator)
8585
flagA = isblascontractable(A, pA) && eltype(A) == TC
8686
if !flagA
87-
A_ = tensoralloc_add(TC, A, pA, false, Val(true), allocator)
88-
Anew = SV(A_, size(A_), strides(A_), 0, A.op)
87+
conjA = A.op === conj
88+
A_ = tensoralloc_add(TC, A, pA, conjA, Val(true), allocator)
89+
Anew = SV(A_)
8990
Anew = tensoradd!(Anew, A, pA, false, One(), Zero(), backend, allocator)
9091
pAnew = trivialpermutation(pA)
9192
else

0 commit comments

Comments
 (0)