Skip to content

Commit 5672c55

Browse files
committed
Merge branch '51-ascii-init' into 'master'
51 -- Use `UInt8(ascii:)` for RESP Tokens Closes #51 See merge request Mordil/swift-redis-nio-client!58
2 parents 6dc4864 + b9d8af0 commit 5672c55

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

Sources/RedisNIO/RESP/RESPTranslator.swift

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ import protocol Foundation.LocalizedError
1616
import NIO
1717

1818
extension UInt8 {
19-
static let newline: UInt8 = 0xA
20-
static let carriageReturn: UInt8 = 0xD
21-
static let dollar: UInt8 = 0x24
22-
static let asterisk: UInt8 = 0x2A
23-
static let plus: UInt8 = 0x2B
24-
static let hyphen: UInt8 = 0x2D
25-
static let colon: UInt8 = 0x3A
19+
static let newline = UInt8(ascii: "\n")
20+
static let carriageReturn = UInt8(ascii: "\r")
21+
static let dollar = UInt8(ascii: "$")
22+
static let asterisk = UInt8(ascii: "*")
23+
static let plus = UInt8(ascii: "+")
24+
static let hyphen = UInt8(ascii: "-")
25+
static let colon = UInt8(ascii: ":")
2626
}
2727

2828
/// Provides methods for translating between byte streams and Swift types

0 commit comments

Comments
 (0)