Skip to content

Commit 7a51361

Browse files
committed
[cxx-interop] Rebase fallout: replace a few instances of swift-5.7 with swift-5.9.
1 parent f2a36ee commit 7a51361

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

docs/CppInteroperability/GettingStartedWithC++Interop.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ module CxxTest {
3232
Add the C++ module to the include path and enable C++ interop:
3333
- Navigate to your project directory
3434
- In `Project` navigate to `Build Settings` -> `Swift Compiler`
35-
- Under `Custom Flags` -> `Other Swift Flags` add `-cxx-compatibility-mode=swift-5.7`
35+
- Under `Custom Flags` -> `Other Swift Flags` add `-cxx-compatibility-mode=swift-5.9`
3636
- Under `Search Paths` -> `Import Paths` add your search path to the C++ module (i.e, `./ProjectName/CxxTest`).
3737

3838
- This should now allow your to import your C++ Module into any `.swift` file.
@@ -81,7 +81,7 @@ After creating your Swift package project, follow the steps [Creating a Module t
8181
- Swift code will be in `Sources/CxxInterop` called `main.swift`
8282
- C++ source code follows the example shown in [Creating a Module to contain your C++ source code](#creating-a-module-to-contain-your-c-source-code)
8383
- Under targets, add the name of your C++ module and the directory containing the Swift code as a target.
84-
- In the target defining your Swift target, add a`dependencies` to the C++ Module, the `path`, `source`, and `swiftSettings` with `unsafeFlags` with the source to the C++ Module, and enable `-cxx-interoperability-mode=swift-5.7`
84+
- In the target defining your Swift target, add a`dependencies` to the C++ Module, the `path`, `source`, and `swiftSettings` with `unsafeFlags` with the source to the C++ Module, and enable `-cxx-interoperability-mode=swift-5.9`
8585

8686
```
8787
//In Package Manifest
@@ -111,7 +111,7 @@ let package = Package(
111111
sources: [ "main.swift" ],
112112
swiftSettings: [.unsafeFlags([
113113
"-I", "Sources/CxxTest",
114-
"-cxx-interoperability-mode=swift-5.7",
114+
"-cxx-interoperability-mode=swift-5.9",
115115
])]
116116
),
117117
]
@@ -144,7 +144,7 @@ After creating your project follow the steps [Creating a Module to contain your
144144
- Create a `CMakeLists.txt` file and configure for your project
145145
- In`add_library` invoke `cxx-support` with the path to the C++ implementation file
146146
- Add the `target_include_directories` with `cxx-support` and path to the C++ Module `${CMAKE_SOURCE_DIR}/Sources/CxxTest`
147-
- Add the `add_executable` to the specific files/directory you would like to generate source, with`SHELL:-cxx-interoperability-mode=swift-5.7`.
147+
- Add the `add_executable` to the specific files/directory you would like to generate source, with`SHELL:-cxx-interoperability-mode=swift-5.9`.
148148
- In the example below we will be following the file structure used in [Creating a Swift Package](#Creating-a-Swift-Package)
149149

150150
```
@@ -167,7 +167,7 @@ target_include_directories(cxx-support PUBLIC
167167
168168
add_executable(CxxInterop ./Sources/CxxInterop/main.swift)
169169
target_compile_options(CxxInterop PRIVATE
170-
"SHELL:-cxx-interoperability-mode=swift-5.7"
170+
"SHELL:-cxx-interoperability-mode=swift-5.9"
171171
target_link_libraries(CxxInterop PRIVATE cxx-support)
172172
173173
```

test/lit.cfg

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -727,8 +727,8 @@ elif swift_test_mode == 'with_cxx_interop':
727727
config.available_features.add("nonexecutable_test")
728728
config.available_features.add("executable_test")
729729
config.available_features.add("with_cxx_interop")
730-
config.swift_frontend_test_options += ' -cxx-interoperability-mode=swift-5.7'
731-
config.swift_driver_test_options += ' -cxx-interoperability-mode=swift-5.7'
730+
config.swift_frontend_test_options += ' -cxx-interoperability-mode=swift-5.9'
731+
config.swift_driver_test_options += ' -cxx-interoperability-mode=swift-5.9'
732732
else:
733733
lit_config.fatal("Unknown test mode %r" % swift_test_mode)
734734

@@ -2381,7 +2381,7 @@ config.substitutions.insert(0, ('%check-cxx-header-in-clang',
23812381
config.substitutions.append(('%env-', config.target_env_prefix))
23822382

23832383
config.substitutions.append(('%target-clangxx', '%s -std=c++11' % config.target_clang))
2384-
config.substitutions.append(('%target-swiftxx-frontend', '%s -cxx-interoperability-mode=swift-5.7' % config.target_swift_frontend))
2384+
config.substitutions.append(('%target-swiftxx-frontend', '%s -cxx-interoperability-mode=swift-5.9' % config.target_swift_frontend))
23852385

23862386
config.substitutions.append(('%target-runtime', config.target_runtime))
23872387

0 commit comments

Comments
 (0)