docs: Document Swift/C++ interoperability feature

pull/13317/head
Albert Tang 3 weeks ago
parent 8778cdfead
commit cafef80899
  1. 13
      docs/markdown/snippets/swift_cxx_interoperability.md

@ -0,0 +1,13 @@
## Swift/C++ interoperability is now supported
It is now possible to create Swift executables that can link to C++ or
Objective-C++ libraries. Only specifying a bridging header for the Swift
target is required.
Swift 5.9 is required to use this feature. Xcode 15 is required if the
Xcode backend is used.
```meson
lib = static_library('mylib', 'mylib.cpp')
exe = executable('prog', 'main.swift', 'mylib.h', link_with: lib)
```
Loading…
Cancel
Save