Skip to content

Commit 27bdc52

Browse files
committed
Add size check to _mul
1 parent 59d031f commit 27bdc52

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/matmul.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ julia> [1 1; 0 1] * [1 0; 1 1]
116116
# We also define the core functionality within _mul to reuse the code elsewhere
117117
mul(A::AbstractMatrix, B::AbstractMatrix) = _mul(A, B)
118118
function _mul(A::AbstractMatrix, B::AbstractMatrix)
119+
matmul_size_check(size(A), size(B))
119120
TS = promote_op(matprod, eltype(A), eltype(B))
120121
mul!(matprod_dest(A, B, TS), A, B)
121122
end

0 commit comments

Comments
 (0)