Fix Swift 5.0

This commit is contained in:
David Evans 2021-06-10 11:18:17 +01:00
parent f769bf4fe1
commit d3a512c397

View File

@ -31,7 +31,7 @@ extension ByteBuffer {
}
mutating func readAndValidateProtocolVersion() throws -> UInt8? {
try self.parseUnwindingIfNeeded { buffer in
try self.parseUnwindingIfNeeded { buffer -> UInt8? in
guard let version = buffer.readInteger(as: UInt8.self) else {
return nil
}
@ -43,7 +43,7 @@ extension ByteBuffer {
}
mutating func readAndValidateReserved() throws -> UInt8? {
try self.parseUnwindingIfNeeded { buffer in
try self.parseUnwindingIfNeeded { buffer -> UInt8? in
guard let reserved = buffer.readInteger(as: UInt8.self) else {
return nil
}