Skip to content

Commit

Permalink
load => loadUnaligned
Browse files Browse the repository at this point in the history
Same fix as swiftlang/swift-package-manager#6929 since the code in swift-syntax is based on what is in SwiftPM.
  • Loading branch information
neonichu authored and ahoppen committed Mar 7, 2024
1 parent 666f336 commit d44705d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/SwiftCompilerPlugin/CompilerPlugin.swift
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit d44705d

Please sign in to comment.