Skip to content

Commit

Permalink
Fix dot product precedence
Browse files Browse the repository at this point in the history
  • Loading branch information
alejandro-isaza committed May 5, 2018
1 parent 1e96fab commit 245bd8f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion Sources/Surge/Arithmetic.swift
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@ public func % <L: UnsafeMemoryAccessible>(lhs: L, rhs: Double) -> [Double] where

// MARK: Dot product

infix operator
infix operator : MultiplicationPrecedence
public func <L: UnsafeMemoryAccessible, R: UnsafeMemoryAccessible>(lhs: L, rhs: R) -> Double where L.Element == Double, R.Element == Double {
return dot(lhs, rhs)
}
Expand Down
1 change: 0 additions & 1 deletion Sources/Surge/Matrix.swift
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,6 @@ public func ==<T> (lhs: Matrix<T>, rhs: Matrix<T>) -> Bool {
return lhs.rows == rhs.rows && lhs.columns == rhs.columns && lhs.grid == rhs.grid
}


// MARK: -

public func add(_ x: Matrix<Float>, _ y: Matrix<Float>) -> Matrix<Float> {
Expand Down

0 comments on commit 245bd8f

Please sign in to comment.