Skip to content

Commit 83d4e05

Browse files
committed
Address review comments
1 parent a26f71d commit 83d4e05

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

Sources/SwiftBasicFormat/Indenter.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ private class Indenter: SyntaxRewriter {
3838
self.shouldIndent = indentFirstLine
3939
}
4040

41-
private func indentIfNeeded() -> [TriviaPiece] {
41+
private func indentationIfNeeded() -> [TriviaPiece] {
4242
if shouldIndent {
4343
shouldIndent = false
4444
return indentation.pieces
@@ -60,7 +60,7 @@ private class Indenter: SyntaxRewriter {
6060
result.reserveCapacity(trivia.count)
6161

6262
for piece in trivia.pieces {
63-
result.append(contentsOf: indentIfNeeded())
63+
result.append(contentsOf: indentationIfNeeded())
6464
switch piece {
6565
case .newlines, .carriageReturns, .carriageReturnLineFeeds:
6666
shouldIndent = true
@@ -76,7 +76,7 @@ private class Indenter: SyntaxRewriter {
7676
result.append(piece)
7777
}
7878
}
79-
result.append(contentsOf: indentIfNeeded())
79+
result.append(contentsOf: indentationIfNeeded())
8080
return Trivia(pieces: result)
8181
}
8282

Sources/SwiftSyntaxBuilder/Indenter.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ extension Trivia {
3030
}
3131

3232
/// Adds a given amount of indentation after every newline in a syntax tree.
33-
@available(*, deprecated, message: "Use 'indented(by:)' from SwiftBasicFormat instead")
33+
@available(*, deprecated, message: "Use 'SyntaxProtocol.indented(by:)' from SwiftBasicFormat instead")
3434
public class Indenter: SyntaxRewriter {
3535
let indentation: Trivia
3636

0 commit comments

Comments
 (0)