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 6b29e2d commit 0f5ac8dCopy full SHA for 0f5ac8d
tools/SwiftSyntax/AbsolutePosition.swift
@@ -24,20 +24,19 @@ public final class AbsolutePosition {
24
}
25
26
internal func add(columns: Int) {
27
- print("adding \(columns) column bytes")
28
self.column += columns
+ self.utf8Offset += columns
29
30
31
internal func add(lines: Int, size: Int) {
32
- print("adding \(lines * size) line bytes")
33
self.line += lines * size
34
self.column = 1
+ self.utf8Offset += lines * size
35
36
37
/// Use some text as a reference for adding to the absolute position,
38
/// taking note of newlines, etc.
39
internal func add(text: String) {
40
- print("adding text: \(text)")
41
for char in text {
42
switch char {
43
case "\n", "\r\n":
0 commit comments