We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 87467ee commit bb5b4c9Copy full SHA for bb5b4c9
Sources/SwiftFormat/PrettyPrint/PrettyPrintBuffer.swift
@@ -125,7 +125,7 @@ struct PrettyPrintBuffer {
125
var lastLength = 0
126
// We are only interested in "\n" we can use the UTF8 view and skip the grapheme clustering.
127
for element in text.utf8 {
128
- if element == 10 {
+ if element == UInt8(ascii: "\n") {
129
lineNumber += 1
130
lastLength = 0
131
} else {
0 commit comments