From 506d12848787b9e5eb2a926ebcaea67a0d72e28b Mon Sep 17 00:00:00 2001 From: Evan Wilde Date: Sat, 19 Apr 2025 23:32:17 -0700 Subject: [PATCH] Fix Bootstrap: UTF8EncoddingError The pass that annotated control-flow positions unreachable after an infinite loop was migrated to pure Swift in PR 79186 (https://github.com/swiftlang/swift/pull/79186). As a result, the C++-only bootstrap compiler is unable to determine that the code-location is unreachable. Placing a fatalError after the infinite while loop. Fixes: rdar://149568740 (cherry picked from commit 783c969e103a3cb424eb660faa3d5222568c1abc) --- stdlib/public/core/UTF8EncodingError.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/stdlib/public/core/UTF8EncodingError.swift b/stdlib/public/core/UTF8EncodingError.swift index 9956b5ec35750..aeaaee5f50866 100644 --- a/stdlib/public/core/UTF8EncodingError.swift +++ b/stdlib/public/core/UTF8EncodingError.swift @@ -256,6 +256,7 @@ extension UTF8 { errors.append(adjustedErr) } } + fatalError() } } }