Skip to content

Commit 7ea1599

Browse files
committed
Add missing availability annotation to test
1 parent 7e4acfa commit 7ea1599

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

test/Macros/macro_expand.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,10 +308,12 @@ func testStringifyWithThrows() throws {
308308
_ = #stringifyAndTry(maybeThrowing())
309309
}
310310

311+
@available(SwiftStdlib 5.1, *)
311312
func throwingFunc() async throws -> Int { 5 }
312313

313314
@freestanding(expression) macro callThrowingFunc<T>(_ body: () -> T) -> T = #externalMacro(module: "MacroDefinition", type: "TryCallThrowingFuncMacro")
314315

316+
@available(SwiftStdlib 5.1, *)
315317
func testThrowingCall() async throws -> Int {
316318
#callThrowingFunc {
317319
[1, 2, 3, 4, 5].map { $0 + 1 }.first!

0 commit comments

Comments
 (0)