File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Sources/PackageDescription Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -49,12 +49,12 @@ extension Version: Hashable {
49
49
// inspired code inside the Swift stdlib.
50
50
let mul : UInt64 = 0x9ddfea08eb382d69
51
51
var result : UInt64 = 0
52
- result = ( result &* mul) ^ UInt64 ( major. hashValue)
53
- result = ( result &* mul) ^ UInt64 ( minor. hashValue)
54
- result = ( result &* mul) ^ UInt64 ( patch. hashValue)
55
- result = prereleaseIdentifiers. reduce ( result, { ( $0 &* mul) ^ UInt64 ( $1. hashValue) } )
52
+ result = ( result &* mul) ^ UInt64 ( bitPattern : Int64 ( major. hashValue) )
53
+ result = ( result &* mul) ^ UInt64 ( bitPattern : Int64 ( minor. hashValue) )
54
+ result = ( result &* mul) ^ UInt64 ( bitPattern : Int64 ( patch. hashValue) )
55
+ result = prereleaseIdentifiers. reduce ( result, { ( $0 &* mul) ^ UInt64 ( bitPattern : Int64 ( $1. hashValue) ) } )
56
56
if let build = buildMetadataIdentifier {
57
- result = ( result &* mul) ^ UInt64 ( build. hashValue)
57
+ result = ( result &* mul) ^ UInt64 ( bitPattern : Int64 ( build. hashValue) )
58
58
}
59
59
return Int ( truncatingBitPattern: result)
60
60
}
You can’t perform that action at this time.
0 commit comments