Skip to content

Commit ad68322

Browse files
authored
Merge pull request #70060 from eeckstein/bridging-comments
add some comments in the bridging headers
2 parents f89b981 + 8681131 commit ad68322

File tree

4 files changed

+14
-0
lines changed

4 files changed

+14
-0
lines changed

include/swift/AST/ASTBridging.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
// Do not add other C++/llvm/swift header files here!
1717
// Function implementations should be placed into ASTBridging.cpp and required header files should be added there.
1818
//
19+
// Pure bridging mode does not permit including any C++/llvm/swift headers.
20+
// See also the comments for `BRIDGING_MODE` in the top-level CMakeLists.txt file.
21+
//
1922
#include "swift/Basic/BasicBridging.h"
2023

2124
#ifdef USED_IN_CPP_SOURCE

include/swift/Basic/BasicBridging.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
// Do not add other C++/llvm/swift header files here!
2121
// Function implementations should be placed into BasicBridging.cpp and required header files should be added there.
2222
//
23+
// Pure bridging mode does not permit including any C++/llvm/swift headers.
24+
// See also the comments for `BRIDGING_MODE` in the top-level CMakeLists.txt file.
25+
//
2326
#include "swift/Basic/BridgedSwiftObject.h"
2427
#include "swift/Basic/Compiler.h"
2528

include/swift/SIL/SILBridging.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
// Function implementations should be placed into SILBridgingImpl.h or SILBridging.cpp and
1818
// required header files should be added there.
1919
//
20+
// Pure bridging mode does not permit including any C++/llvm/swift headers.
21+
// See also the comments for `BRIDGING_MODE` in the top-level CMakeLists.txt file.
22+
//
2023
#include "swift/AST/ASTBridging.h"
2124

2225
#ifdef USED_IN_CPP_SOURCE

include/swift/SILOptimizer/OptimizerBridging.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
// Function implementations should be placed into OptimizerBridgingImpl.h or PassManager.cpp
1818
// (under OptimizerBridging) andrequired header files should be added there.
1919
//
20+
// Pure bridging mode does not permit including any C++/llvm/swift headers.
21+
// See also the comments for `BRIDGING_MODE` in the top-level CMakeLists.txt file.
22+
//
2023
#include "swift/AST/ASTBridging.h"
2124
#include "swift/SIL/SILBridging.h"
2225

@@ -26,6 +29,8 @@
2629

2730
#else // USED_IN_CPP_SOURCE
2831

32+
// Pure bridging mode does not permit including any C++/llvm/swift headers.
33+
// See also the comments for `BRIDGING_MODE` in the top-level CMakeLists.txt file.
2934
#ifdef SWIFT_SIL_SILVALUE_H
3035
#error "should not include swift headers into bridging header"
3136
#endif

0 commit comments

Comments
 (0)