File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed
Tests/SwiftFormatTests/Rules Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -386,8 +386,7 @@ extension DocumentationComment {
386
386
let prefixWidth =
387
387
4
388
388
+ joiningTrivia. map {
389
- if case . spaces( let n) = $0 { return n }
390
- else { return 0 }
389
+ if case . spaces( let n) = $0 { return n } else { return 0 }
391
390
} . reduce ( 0 , + )
392
391
393
392
let options = MarkupFormatter . Options (
@@ -498,6 +497,7 @@ extension DocumentationComment.Parameter {
498
497
let label = asSingle ? " Parameter \( name) : " : " \( name) : "
499
498
let summaryWithLabel = summary. prefixed ( with: label)
500
499
return ListItem (
501
- [ summaryWithLabel] + comment. bodyNodes. map { $0 as! BlockMarkup } )
500
+ [ summaryWithLabel] + comment. bodyNodes. map { $0 as! BlockMarkup }
501
+ )
502
502
}
503
503
}
Original file line number Diff line number Diff line change @@ -156,7 +156,7 @@ class StandardizeDocumentationCommentsTests: LintOrFormatRuleTestCase {
156
156
configuration: Self . configuration
157
157
)
158
158
}
159
-
159
+
160
160
func testDetailedParameters( ) {
161
161
assertFormatting (
162
162
StandardizeDocumentationComments . self,
@@ -232,9 +232,9 @@ class StandardizeDocumentationCommentsTests: LintOrFormatRuleTestCase {
232
232
configuration: Self . configuration
233
233
)
234
234
}
235
-
235
+
236
236
// MARK: Nominal decl tests
237
-
237
+
238
238
func testActorDecl( ) {
239
239
assertFormatting (
240
240
StandardizeDocumentationComments . self,
@@ -255,7 +255,7 @@ class StandardizeDocumentationCommentsTests: LintOrFormatRuleTestCase {
255
255
configuration: Self . configuration
256
256
)
257
257
}
258
-
258
+
259
259
func testAssociatedTypeDecl( ) {
260
260
assertFormatting (
261
261
StandardizeDocumentationComments . self,
@@ -276,7 +276,7 @@ class StandardizeDocumentationCommentsTests: LintOrFormatRuleTestCase {
276
276
configuration: Self . configuration
277
277
)
278
278
}
279
-
279
+
280
280
func testClassDecl( ) {
281
281
assertFormatting (
282
282
StandardizeDocumentationComments . self,
You can’t perform that action at this time.
0 commit comments