Skip to content

Commit

Permalink
Code format, add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
t-ae committed Nov 9, 2019
1 parent 2ed9124 commit 6c89c2f
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions Sources/Swim/Utility/Complex.swift
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// TODO: Replace with swift-numerics implementation
// https://github.com/apple/swift-numerics

public protocol ComplexProtocol: SignedNumeric, CustomStringConvertible, ExpressibleByFloatLiteral, Hashable {
associatedtype T: BinaryFloatingPoint

Expand Down Expand Up @@ -81,7 +84,7 @@ extension ComplexProtocol {
}

@inlinable
public static func += (lhs: inout Self, rhs: Self) {
public static func +=(lhs: inout Self, rhs: Self) {
lhs.real += rhs.real
lhs.imag += rhs.imag
}
Expand All @@ -92,7 +95,7 @@ extension ComplexProtocol {
}

@inlinable
public static func -= (lhs: inout Self, rhs: Self) {
public static func -=(lhs: inout Self, rhs: Self) {
lhs.real -= rhs.real
lhs.imag -= rhs.imag
}
Expand All @@ -105,7 +108,7 @@ extension ComplexProtocol {
}

@inlinable
public static func *= (lhs: inout Self, rhs: Self) {
public static func *=(lhs: inout Self, rhs: Self) {
lhs = lhs * rhs
}

Expand All @@ -117,7 +120,7 @@ extension ComplexProtocol {
}

@inlinable
public static func /= (lhs: inout Self, rhs: Self) {
public static func /=(lhs: inout Self, rhs: Self) {
lhs = lhs / rhs
}
}
Expand Down

0 comments on commit 6c89c2f

Please sign in to comment.