Skip to content

Commit 2c2a831

Browse files
committed
Remove blank lines at the end of doc comments.
1 parent deb56e1 commit 2c2a831

File tree

7 files changed

+0
-26
lines changed

7 files changed

+0
-26
lines changed

Sources/System/FilePath/FilePath.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@
4040
/// However, the rules for path equivalence
4141
/// are file-system–specific and have additional considerations
4242
/// like case insensitivity, Unicode normalization, and symbolic links.
43-
///
4443
public struct FilePath {
4544
internal var _storage: SystemString
4645

Sources/System/FilePath/FilePathComponentView.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ extension FilePath {
2828
///
2929
/// path.components.removeAll { $0.kind == .currentDirectory }
3030
/// // path is "/home/username/bin/scripts/tree"
31-
///
3231
public struct ComponentView {
3332
internal var _path: FilePath
3433
internal var _start: SystemString.Index

Sources/System/FilePath/FilePathComponents.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ extension FilePath {
5454
/// file.kind == .regular // true
5555
/// file.extension // "txt"
5656
/// path.append(file) // path is "/tmp/foo.txt"
57-
///
5857
public struct Component {
5958
internal var _path: FilePath
6059
internal var _range: Range<SystemString.Index>

Sources/System/FilePath/FilePathString.swift

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ extension FilePath.Component {
9898
///
9999
/// - Parameter platformString: A pointer to a null-terminated platform
100100
/// string.
101-
///
102101
public init?(platformString: UnsafePointer<CInterop.PlatformChar>) {
103102
self.init(_platformString: platformString)
104103
}
@@ -187,7 +186,6 @@ extension FilePath.Root {
187186
///
188187
/// - Parameter platformString: A pointer to a null-terminated platform
189188
/// string.
190-
///
191189
public init?(platformString: UnsafePointer<CInterop.PlatformChar>) {
192190
self.init(_platformString: platformString)
193191
}

Sources/System/FilePath/FilePathSyntax.swift

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ extension FilePath {
6565
/// path.starts(with: "/usr/bin/ls") // true
6666
/// path.starts(with: "/usr/bin/ls///") // true
6767
/// path.starts(with: "/us") // false
68-
///
6968
public func starts(with other: FilePath) -> Bool {
7069
guard !other.isEmpty else { return true }
7170
return self.root == other.root && components.starts(
@@ -85,7 +84,6 @@ extension FilePath {
8584
/// path.ends(with: "usr/bin/ls") // true
8685
/// path.ends(with: "/usr/bin/ls///") // true
8786
/// path.ends(with: "/ls") // false
88-
///
8987
public func ends(with other: FilePath) -> Bool {
9088
if other.root != nil {
9189
// TODO: anything tricky here for Windows?
@@ -145,7 +143,6 @@ extension FilePath {
145143
/// path.root = nil // path is #"foo\bar"#
146144
/// path.root = "C:" // path is #"C:foo\bar"#
147145
/// path.root = #"C:\"# // path is #"C:\foo\bar"#
148-
///
149146
public var root: FilePath.Root? {
150147
get {
151148
guard _hasRoot else { return nil }
@@ -178,7 +175,6 @@ extension FilePath {
178175
/// * `\\?\device\folder\file.exe => folder\file.exe`
179176
/// * `\\server\share\file => file`
180177
/// * `\ => ""`
181-
///
182178
public __consuming func removingRoot() -> FilePath {
183179
var copy = self
184180
copy.root = nil
@@ -209,7 +205,6 @@ extension FilePath {
209205
/// * `\\?\UNC\server\share\bar.exe => bar.exe`
210206
/// * `\\server\share => nil`
211207
/// * `\\?\UNC\server\share\ => nil`
212-
///
213208
public var lastComponent: Component? { components.last }
214209

215210
/// Creates a new path with everything up to but not including
@@ -247,7 +242,6 @@ extension FilePath {
247242
/// path.removeLastComponent() == true // path is "/usr"
248243
/// path.removeLastComponent() == true // path is "/"
249244
/// path.removeLastComponent() == false // path is "/"
250-
///
251245
@discardableResult
252246
public mutating func removeLastComponent() -> Bool {
253247
defer { _invariantCheck() }
@@ -271,7 +265,6 @@ extension FilePath.Component {
271265
/// * `Foo.app => app`
272266
/// * `.hidden => nil`
273267
/// * `.. => nil`
274-
///
275268
public var `extension`: String? {
276269
guard let range = _extensionRange() else { return nil }
277270
return _slice[range].string
@@ -285,7 +278,6 @@ extension FilePath.Component {
285278
/// * `Foo.app => Foo`
286279
/// * `.hidden => .hidden`
287280
/// * `.. => ..`
288-
///
289281
public var stem: String {
290282
_slice[_stemRange()].string
291283
}
@@ -322,7 +314,6 @@ extension FilePath {
322314
/// path.extension = "o" // path is "/tmp/file.o"
323315
/// path.extension = nil // path is "/tmp/file"
324316
/// path.extension = "" // path is "/tmp/file."
325-
///
326317
public var `extension`: String? {
327318
get { lastComponent?.extension }
328319
set {
@@ -451,7 +442,6 @@ extension FilePath {
451442
/// path.removePrefix("/usr/bin") // false
452443
/// path.removePrefix("/us") // false
453444
/// path.removePrefix("/usr/local") // true, path is "bin"
454-
///
455445
public mutating func removePrefix(_ prefix: FilePath) -> Bool {
456446
defer { _invariantCheck() }
457447
// FIXME: Should Windows have more nuanced semantics?
@@ -473,7 +463,6 @@ extension FilePath {
473463
/// path.append(comp)
474464
/// }
475465
/// // path is "/tmp/foo/bar/../baz"
476-
///
477466
public mutating func append(_ component: __owned FilePath.Component) {
478467
defer { _invariantCheck() }
479468
_append(unchecked: component._slice)
@@ -488,7 +477,6 @@ extension FilePath {
488477
/// path.append(["usr", "local"]) // path is "/usr/local"
489478
/// let otherPath: FilePath = "/bin/ls"
490479
/// path.append(otherPath.components) // path is "/usr/local/bin/ls"
491-
///
492480
public mutating func append<C: Collection>(
493481
_ components: __owned C
494482
) where C.Element == FilePath.Component {
@@ -510,7 +498,6 @@ extension FilePath {
510498
/// path.append("/var/www/website") // "/var/www/website"
511499
/// path.append("static/assets") // "/var/www/website/static/assets"
512500
/// path.append("/main.css") // "/var/www/website/static/assets/main.css"
513-
///
514501
public mutating func append(_ other: __owned String) {
515502
defer { _invariantCheck() }
516503
guard !other.utf8.isEmpty else { return }
@@ -524,7 +511,6 @@ extension FilePath {
524511

525512
// TODO(Windows docs): example with roots
526513
/// Non-mutating version of `append(_:Component)`.
527-
///
528514
public __consuming func appending(_ other: __owned Component) -> FilePath {
529515
var copy = self
530516
copy.append(other)
@@ -533,7 +519,6 @@ extension FilePath {
533519

534520
// TODO(Windows docs): example with roots
535521
/// Non-mutating version of `append(_:C)`.
536-
///
537522
public __consuming func appending<C: Collection>(
538523
_ components: __owned C
539524
) -> FilePath where C.Element == FilePath.Component {
@@ -544,7 +529,6 @@ extension FilePath {
544529

545530
// TODO(Windows docs): example with roots
546531
/// Non-mutating version of `append(_:String)`.
547-
///
548532
public __consuming func appending(_ other: __owned String) -> FilePath {
549533
var copy = self
550534
copy.append(other)
@@ -566,7 +550,6 @@ extension FilePath {
566550
/// var path: FilePath = "/tmp"
567551
/// path.push("dir/file.txt") // path is "/tmp/dir/file.txt"
568552
/// path.push("/bin") // path is "/bin"
569-
///
570553
public mutating func push(_ other: __owned FilePath) {
571554
defer { _invariantCheck() }
572555
guard other.root == nil else {
@@ -579,7 +562,6 @@ extension FilePath {
579562

580563
// TODO(Windows docs): examples and docs with roots
581564
/// Non-mutating version of `push()`.
582-
///
583565
public __consuming func pushing(_ other: __owned FilePath) -> FilePath {
584566
var copy = self
585567
copy.push(other)

Sources/System/FilePath/FilePathWindows.swift

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,15 +156,13 @@ internal struct WindowsRootInfo {
156156
/// * Traditional disk: `C:\`, `C:`
157157
/// * Device disk: `\\.\C:\`, `\\?\C:\`
158158
/// * UNC: `\\server\e:\`, `\\?\UNC\server\e:\`
159-
///
160159
case drive(Character)
161160

162161
// TODO: GUID type?
163162
/// A volume with a GUID in a non-traditional path
164163
///
165164
/// * UNC: `\\host\Volume{0000-...}\`, `\\.\UNC\host\Volume{0000-...}\`
166165
/// * Device roots: `\\.\Volume{0000-...}\`, `\\?\Volume{000-...}\`
167-
///
168166
case guid(String)
169167

170168
// TODO: Legacy DOS devices, such as COM1?

Tests/SystemTests/FilePathTests/FilePathExtras.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ extension FilePath {
5151

5252
/// Whether a lexically-normalized `self` contains a lexically-normalized
5353
/// `other`.
54-
///
5554
public func lexicallyContains(_ other: FilePath) -> Bool {
5655
guard !other.isEmpty else { return true }
5756
guard !isEmpty else { return false }

0 commit comments

Comments
 (0)