From dd67ac0d795510edbbc9de1bd182d47f78eaf079 Mon Sep 17 00:00:00 2001 From: Simon Whitty Date: Mon, 16 Nov 2026 07:15:58 +1100 Subject: [PATCH] Use Swift.CancellationError in Task.sleepUntilCancelled Inside an extension of Task, CancellationError() resolves to the deprecated Task.CancellationError, which produces a deprecation warning. --- FlyingFox/Tests/HTTPServerTests.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FlyingFox/Tests/HTTPServerTests.swift b/FlyingFox/Tests/HTTPServerTests.swift index 7c0ea93..a019574 100644 --- a/FlyingFox/Tests/HTTPServerTests.swift +++ b/FlyingFox/Tests/HTTPServerTests.swift @@ -876,7 +876,7 @@ extension Task where Success == Never, Failure == Never { // always called after the body, so the continuation is stored continuation.withLock { $0 }?.resume() } - throw CancellationError() + throw Swift.CancellationError() } }