Skip to content

Commit be0d11d

Browse files
committed
Fix formatting
1 parent 451000d commit be0d11d

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

Examples/EmbeddedConcurrency/Sources/EmbeddedConcurrencyApp/App.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import _Concurrency
66
typealias DefaultExecutorFactory = JavaScriptEventLoop
77
#endif
88

9-
nonisolated(unsafe) var testsPassed = 0
10-
nonisolated(unsafe) var testsFailed = 0
9+
@MainActor var testsPassed = 0
10+
@MainActor var testsFailed = 0
1111

1212
@MainActor
1313
func check(_ condition: Bool, _ message: String) {
@@ -23,6 +23,7 @@ func check(_ condition: Bool, _ message: String) {
2323

2424
@main
2525
struct App {
26+
@MainActor
2627
static func main() async throws(JSException) {
2728
JavaScriptEventLoop.installGlobalExecutor()
2829

Sources/JavaScriptKit/BasicObjects/JSTypedArray.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,9 @@ public final class JSTypedArray<Traits>: JSBridgedClass, ExpressibleByArrayLiter
121121
/// argument is valid only for the duration of the closure's execution.
122122
/// - Returns: The return value, if any, of the `body`async closure parameter.
123123
@available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
124-
public func withUnsafeBytesAsync<R, E: Error>(_ body: (UnsafeBufferPointer<Element>) async throws(E) -> R) async throws(E) -> R {
124+
public func withUnsafeBytesAsync<R, E: Error>(
125+
_ body: (UnsafeBufferPointer<Element>) async throws(E) -> R
126+
) async throws(E) -> R {
125127
let buffer = UnsafeMutableBufferPointer<Element>.allocate(capacity: length)
126128
defer { buffer.deallocate() }
127129
copyMemory(to: buffer)

0 commit comments

Comments
 (0)