Skip to content

Commit

Permalink
Bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
Andy Ferris committed Sep 15, 2017
1 parent bebf831 commit 7b0de64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions base/linalg/adjoint.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Conceptually, this is intended create the "dual vector" of `v` (note however tha
is strictly an `AbstractMatrix`). Note also that the output is a view of `v`.
"""
@inline adjoint(vec::AbstractVector) = RowVector(_map(adjoint, vec))
@inline adjoint(rowvec::RowVector) = _adjoint(parent(rowvec))
@inline adjoint(rowvec::RowVector) = _map(adjoint, parent(rowvec))

"""
adjoint(m::AbstractMatrix)
Expand All @@ -22,7 +22,7 @@ recursively to the elements.
"""
function adjoint(a::AbstractMatrix)
(ind1, ind2) = indices(a)
b = similar(a, adjoint_type(eltype(a)), (ind2, ind1))
b = similar(a, promote_op(adjoint, eltype(a)), (ind2, ind1))
adjoint!(b, a)
end

Expand Down

0 comments on commit 7b0de64

Please sign in to comment.