Skip to content

Commit f477389

Browse files
authored
Merge pull request #264 from apple/adjust-toolchain-support
Adjust toolchain support
2 parents 4bbe3f3 + bc4e6e3 commit f477389

File tree

7 files changed

+37
-24
lines changed

7 files changed

+37
-24
lines changed

.github/workflows/pull_request.yml

Lines changed: 28 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,39 @@ jobs:
99
name: Test
1010
uses: swiftlang/github-workflows/.github/workflows/swift_package_test.yml@main
1111
with:
12+
swift_flags: "-Xbuild-tools-swiftc -DSYSTEM_CI"
13+
enable_linux_checks: true
1214
linux_os_versions: '["noble", "jammy", "focal"]'
13-
linux_exclude_swift_versions: '[{"os_version": "focal", "swift_version": "nightly-main"}, {"os_version": "focal", "swift_version": "nightly-6.2"}, {"os_version": "focal", "swift_version": "6.2"}, {"os_version": "noble", "swift_version": "5.9"}, {"os_version": "noble", "swift_version": "5.10"}]'
15+
linux_exclude_swift_versions: |
16+
[
17+
{"swift_version": "5.9"},
18+
{"swift_version": "5.10"},
19+
{"os_version": "focal", "swift_version": "nightly-6.2"},
20+
{"os_version": "focal", "swift_version": "6.2"},
21+
{"os_version": "focal", "swift_version": "nightly-main"},
22+
]
1423
enable_macos_checks: true
15-
# FIXME: https://github.com/swiftlang/github-workflows/pull/140
16-
# Xcode 16.0 and 16.1 are not actually available
17-
macos_exclude_xcode_versions: |
24+
macos_exclude_xcode_versions: '[]'
25+
enable_windows_checks: true
26+
windows_exclude_swift_versions: |
1827
[
19-
{"xcode_version": "16.0"},
20-
{"xcode_version": "16.1"},
28+
{"swift_version": "5.9"},
29+
{"swift_version": "5.10"}
2130
]
22-
swift_flags: "-Xbuild-tools-swiftc -DSYSTEM_CI"
2331
enable_linux_static_sdk_build: true
24-
linux_static_sdk_exclude_swift_versions: '[{"os_version": "focal", "swift_version": "nightly-main"}, {"os_version": "focal", "swift_version": "nightly-6.2"}, {"os_version": "focal", "swift_version": "6.2"}]'
32+
linux_static_sdk_exclude_swift_versions: |
33+
[
34+
{"os_version": "focal", "swift_version": "nightly-6.2"},
35+
{"os_version": "focal", "swift_version": "6.2"},
36+
{"os_version": "focal", "swift_version": "nightly-main"},
37+
]
2538
enable_wasm_sdk_build: true
26-
wasm_exclude_swift_versions: '[{"os_version": "focal", "swift_version": "nightly-main"}, {"os_version": "focal", "swift_version": "nightly-6.2"}, {"os_version": "focal", "swift_version": "6.2"}]'
39+
wasm_exclude_swift_versions: |
40+
[
41+
{"os_version": "focal", "swift_version": "nightly-6.2"},
42+
{"os_version": "focal", "swift_version": "6.2"},
43+
{"os_version": "focal", "swift_version": "nightly-main"},
44+
]
2745
2846
build-abi-stable:
2947
name: Build ABI Stable
@@ -34,13 +52,7 @@ jobs:
3452
enable_windows_checks: false
3553
# Only build
3654
macos_build_command: "xcrun swift build --build-tests"
37-
# FIXME: https://github.com/swiftlang/github-workflows/pull/140
38-
# Xcode 16.0 and 16.1 are not actually available
39-
macos_exclude_xcode_versions: |
40-
[
41-
{"xcode_version": "16.0"},
42-
{"xcode_version": "16.1"},
43-
]
55+
macos_exclude_xcode_versions: '[]'
4456
# Enable availability to match ABI stable verion of system.
4557
swift_flags: "-Xbuild-tools-swiftc -DSYSTEM_CI -Xbuild-tools-swiftc -DSYSTEM_ABI_STABLE"
4658

Package.swift

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// swift-tools-version:5.9
1+
// swift-tools-version:6.0
22
//===----------------------------------------------------------------------===//
33
//
44
// This source file is part of the Swift System open source project
@@ -139,5 +139,6 @@ let package = Package(
139139
exclude: testsToExclude,
140140
cSettings: cSettings,
141141
swiftSettings: swiftSettings),
142-
])
143-
142+
],
143+
swiftLanguageVersions: [.v5]
144+
)

Sources/System/Internals/Exports.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ extension String {
140140
return
141141

142142
#else
143-
self.init(validatingUTF8: platformString)
143+
self.init(validatingCString: platformString)
144144
#endif
145145
}
146146

Tests/SystemTests/FilePathTests/FilePathComponentsTest.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ final class FilePathComponentsTest: XCTestCase {
107107

108108
func expect(
109109
_ s: String,
110-
_ file: StaticString = #file,
110+
_ file: StaticString = #filePath,
111111
_ line: UInt = #line
112112
) {
113113
if path == FilePath(s) { return }

Tests/SystemTests/FilePathTests/FilePathSyntaxTest.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -850,7 +850,7 @@ final class FilePathSyntaxTest: XCTestCase {
850850

851851
func expect(
852852
_ s: String,
853-
_ file: StaticString = #file,
853+
_ file: StaticString = #filePath,
854854
_ line: UInt = #line
855855
) {
856856
if path == FilePath(s) { return }

Tests/SystemTests/TestingInfrastructure.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ extension Trace.Entry {
3737
#endif // ENABLE_MOCKING
3838

3939
// To aid debugging, force failures to fatal error
40-
internal var forceFatalFailures = false
40+
internal let forceFatalFailures = false
4141

4242
internal protocol TestCase {
4343
// TODO: want a source location stack, more fidelity, kinds of stack entries, etc

Tests/SystemTests/UtilTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class UtilTests: XCTestCase {
3434
func testCStringArray() {
3535
func check(
3636
_ array: [String],
37-
file: StaticString = #file,
37+
file: StaticString = #filePath,
3838
line: UInt = #line
3939
) {
4040
array._withCStringArray { carray in

0 commit comments

Comments
 (0)