Skip to content

Commit 1b34721

Browse files
neonichuahoppen
authored andcommitted
load => loadUnaligned
Same fix as swiftlang/swift-package-manager#6929 since the code in swift-syntax is based on what is in SwiftPM.
1 parent ffa3cd6 commit 1b34721

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/SwiftCompilerPlugin/CompilerPlugin.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ internal struct PluginHostConnection: MessageConnection {
200200

201201
// Decode the count.
202202
let count = header.withUnsafeBytes {
203-
UInt64(littleEndian: $0.load(as: UInt64.self))
203+
UInt64(littleEndian: $0.loadUnaligned(as: UInt64.self))
204204
}
205205
guard count >= 2 else {
206206
throw PluginMessageError.invalidPayloadSize

0 commit comments

Comments
 (0)