Skip to content

Commit

Permalink
DocC-fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
sdpopov-keyvariable committed Oct 24, 2023
1 parent cfeb486 commit 595efae
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 21 deletions.
4 changes: 2 additions & 2 deletions Sources/kvKit/KvDebug.swift
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public class KvDebug {


#if DEBUG
/// Analog of standard ``Swift/assert``() providing ability to continue execution.
/// Analog of standard `assert` providing ability to continue execution.
///
/// - Note: Use *Swift Error Breakpoint* to pause execution.
///
Expand All @@ -142,7 +142,7 @@ public class KvDebug {
}

#else // !DEBUG
/// Analog of standard ``Swift/assert``() providing ability to continue execution.
/// Analog of standard `assert` providing ability to continue execution.
///
/// - Note: Use *Swift Error Breakpoint* to pause execution.
///
Expand Down
4 changes: 2 additions & 2 deletions Sources/kvKit/KvMetalKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ extension KvMetalKit {

/// Calculates 1D-grid for given *pipelineState*.
///
/// See ``init(_:texture1D:)``, ``threadgroupSize(_:width)``.
/// See ``init(_:texture1D:)``, ``threadgroupSize(_:width:)``.
@inlinable
public init(_ pipelineState: MTLComputePipelineState, width: Int) {
self.init(pipelineState,
Expand All @@ -314,7 +314,7 @@ extension KvMetalKit {

/// Calculates 1D-grid for given *pipelineState* of the same size as given *texture1D*.
///
/// See ``init(_:width:)``, ``threadgroupSize(_:width)``.
/// See ``init(_:width:)``, ``threadgroupSize(_:width:)``.
@inlinable
public init(_ pipelineState: MTLComputePipelineState, texture1D: MTLTexture) {
self.init(pipelineState, width: texture1D.width)
Expand Down
32 changes: 16 additions & 16 deletions Sources/kvTestKit/KvMathTestKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,98 +27,98 @@ import XCTest



/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<T : KvNumericallyEquatable>(_ result: T, _ expected: T, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: T.isEqual(_:to:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<T : KvNumericallyEquatable>(_ result: T?, _ expected: T?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: T.isEqual(_:to:), message())
}


/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Vector2, _ expected: Math.Vector2, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Vector2?, _ expected: Math.Vector2?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Vector3, _ expected: Math.Vector3, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Vector3?, _ expected: Math.Vector3?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Vector4, _ expected: Math.Vector4, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Vector4?, _ expected: Math.Vector4?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Quaternion, _ expected: Math.Quaternion, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Quaternion?, _ expected: Math.Quaternion?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Matrix2x2, _ expected: Math.Matrix2x2, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Matrix2x2?, _ expected: Math.Matrix2x2?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Matrix3x3, _ expected: Math.Matrix3x3, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Matrix3x3?, _ expected: Math.Matrix3x3?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Matrix4x4, _ expected: Math.Matrix4x4, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
}

/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *result* and *expectation* are not numerically equal.
@inlinable
public func KvAssertEqual<Math : KvMathScope>(_ math: Math.Type, _ result: Math.Matrix4x4?, _ expected: Math.Matrix4x4?, _ message: @autoclosure () -> String = "") {
KvAssertEqual(result, expected, by: Math.isEqual(_:_:), message())
Expand Down
2 changes: 1 addition & 1 deletion Sources/kvTestKit/KvTestKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import XCTest



/// Invokes ``XCTFail``() when *result* and *expectation* are not both `nil` or *isEqual*(*result*, *expectation*) doesn't return *true*.
/// Invokes `XCTFail` when *result* and *expectation* are not both `nil` or *isEqual*(*result*, *expectation*) doesn't return *true*.
@inlinable
public func KvAssertEqual<R, E>(_ result: R?, _ expectation: E?, by isEqual: (R, E) -> Bool, _ message: @autoclosure () -> String = "") {
switch (result, expectation) {
Expand Down

0 comments on commit 595efae

Please sign in to comment.