diff --git a/Sources/System/Internals/Exports.swift b/Sources/System/Internals/Exports.swift index d18102a..c7d9944 100644 --- a/Sources/System/Internals/Exports.swift +++ b/Sources/System/Internals/Exports.swift @@ -140,7 +140,7 @@ extension String { return #else - self.init(validatingUTF8: platformString) + self.init(validatingCString: platformString) #endif } diff --git a/Tests/SystemTests/FilePathTests/FilePathComponentsTest.swift b/Tests/SystemTests/FilePathTests/FilePathComponentsTest.swift index d72d59a..675b533 100644 --- a/Tests/SystemTests/FilePathTests/FilePathComponentsTest.swift +++ b/Tests/SystemTests/FilePathTests/FilePathComponentsTest.swift @@ -107,7 +107,7 @@ final class FilePathComponentsTest: XCTestCase { func expect( _ s: String, - _ file: StaticString = #file, + _ file: StaticString = #filePath, _ line: UInt = #line ) { if path == FilePath(s) { return } diff --git a/Tests/SystemTests/FilePathTests/FilePathSyntaxTest.swift b/Tests/SystemTests/FilePathTests/FilePathSyntaxTest.swift index 6e03189..0fdfbc2 100644 --- a/Tests/SystemTests/FilePathTests/FilePathSyntaxTest.swift +++ b/Tests/SystemTests/FilePathTests/FilePathSyntaxTest.swift @@ -850,7 +850,7 @@ final class FilePathSyntaxTest: XCTestCase { func expect( _ s: String, - _ file: StaticString = #file, + _ file: StaticString = #filePath, _ line: UInt = #line ) { if path == FilePath(s) { return } diff --git a/Tests/SystemTests/UtilTests.swift b/Tests/SystemTests/UtilTests.swift index bfd2134..e952320 100644 --- a/Tests/SystemTests/UtilTests.swift +++ b/Tests/SystemTests/UtilTests.swift @@ -34,7 +34,7 @@ class UtilTests: XCTestCase { func testCStringArray() { func check( _ array: [String], - file: StaticString = #file, + file: StaticString = #filePath, line: UInt = #line ) { array._withCStringArray { carray in