File tree Expand file tree Collapse file tree 2 files changed +1
-9
lines changed
Sources/FoundationEssentials Expand file tree Collapse file tree 2 files changed +1
-9
lines changed Original file line number Diff line number Diff line change @@ -49,8 +49,6 @@ package struct Platform {
4949 _pageSize
5050 }
5151
52- // FIXME: Windows SEPARATOR
53- static let PATH_SEPARATOR : Character = " / "
5452 static let MAX_HOSTNAME_LENGTH = 1024
5553
5654 static func roundDownToMultipleOfPageSize( _ size: Int ) -> Int {
Original file line number Diff line number Diff line change @@ -581,13 +581,7 @@ extension _ProcessInfo {
581581 guard let processPath = CommandLine . arguments. first else {
582582 return " "
583583 }
584-
585- if let lastSlash = processPath. lastIndex ( of: Platform . PATH_SEPARATOR) {
586- return String ( processPath [
587- processPath. index ( after: lastSlash) ..< processPath. endIndex] )
588- }
589-
590- return processPath
584+ return processPath. lastPathComponent
591585 }
592586
593587#if os(macOS)
You can’t perform that action at this time.
0 commit comments