Skip to content

Commit c91a363

Browse files
committed
feat: Add @sendable annotations for Swift 6 support
1 parent 2a2fa27 commit c91a363

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Sources/SagaUtils/SwiftSoupProcessor.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ import SwiftSoup
1818
/// )
1919
/// ```
2020
public func swiftSoupProcessor<M>(
21-
_ transformations: ((Document, Item<M>) throws -> Void)...
22-
) -> (Item<M>) async -> Void {
21+
_ transformations: (@Sendable (Document, Item<M>) throws -> Void)...
22+
) -> @Sendable (Item<M>) async -> Void {
2323
return { item in
2424
do {
2525
let doc = try SwiftSoup.parseBodyFragment(item.body)

Sources/SagaUtils/SwiftSoupTransformations.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public func generateTOC<M>(_ doc: Document, item: Item<M>) throws {
2424
///
2525
/// Also adds heading anchors, so there is no need to also use ``addHeadingAnchors``.
2626
/// - Parameter placeholder: The placeholder string to look for.
27-
public func generateTOC<M>(placeholder: String) -> (Document, Item<M>) throws -> Void {
27+
public func generateTOC<M>(placeholder: String) -> @Sendable (Document, Item<M>) throws -> Void {
2828
return { doc, _ in
2929
try _generateTOC(doc, placeholder: placeholder)
3030
}

0 commit comments

Comments
 (0)