From d44705d9c1de02ef0f1d7e6d61e527506f99f7ca Mon Sep 17 00:00:00 2001 From: Boris Buegling Date: Wed, 25 Oct 2023 11:29:53 -0700 Subject: [PATCH] load => loadUnaligned Same fix as https://github.com/apple/swift-package-manager/pull/6929 since the code in swift-syntax is based on what is in SwiftPM. --- Sources/SwiftCompilerPlugin/CompilerPlugin.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/SwiftCompilerPlugin/CompilerPlugin.swift b/Sources/SwiftCompilerPlugin/CompilerPlugin.swift index 2e8c2edbd76..30f56c8aa58 100644 --- a/Sources/SwiftCompilerPlugin/CompilerPlugin.swift +++ b/Sources/SwiftCompilerPlugin/CompilerPlugin.swift @@ -210,7 +210,7 @@ internal struct PluginHostConnection: MessageConnection { // Decode the count. let count = header.withUnsafeBytes { - UInt64(littleEndian: $0.load(as: UInt64.self)) + UInt64(littleEndian: $0.loadUnaligned(as: UInt64.self)) } guard count >= 2 else { throw PluginMessageError.invalidPayloadSize