diff --git a/Sources/SwiftFormat/Rules/AlwaysUseLiteralForEmptyCollectionInit.swift b/Sources/SwiftFormat/Rules/AlwaysUseLiteralForEmptyCollectionInit.swift index b73e0ba4..973e2277 100644 --- a/Sources/SwiftFormat/Rules/AlwaysUseLiteralForEmptyCollectionInit.swift +++ b/Sources/SwiftFormat/Rules/AlwaysUseLiteralForEmptyCollectionInit.swift @@ -86,7 +86,7 @@ public final class AlwaysUseLiteralForEmptyCollectionInit : SyntaxFormatRule { if replacement.typeAnnotation == nil { // Drop trailing trivia after pattern because ':' has to appear connected to it. replacement.pattern = node.pattern.with(\.trailingTrivia, []) - // Add explicit type annotiation: ': []` + // Add explicit type annotation: ': []` replacement.typeAnnotation = .init(type: type.with(\.leadingTrivia, .space) .with(\.trailingTrivia, .space)) } @@ -109,7 +109,7 @@ public final class AlwaysUseLiteralForEmptyCollectionInit : SyntaxFormatRule { if replacement.typeAnnotation == nil { // Drop trailing trivia after pattern because ':' has to appear connected to it. replacement.pattern = node.pattern.with(\.trailingTrivia, []) - // Add explicit type annotiation: ': []` + // Add explicit type annotation: ': []` replacement.typeAnnotation = .init(type: type.with(\.leadingTrivia, .space) .with(\.trailingTrivia, .space)) }