Skip to content

Commit e2f0cef

Browse files
committed
[Interop] replace unnecessary uses of _CXX_INTEROP_STRINGIFY
1 parent 0253725 commit e2f0cef

File tree

1 file changed

+9
-9
lines changed
  • lib/ClangImporter/SwiftBridging/swift

1 file changed

+9
-9
lines changed

lib/ClangImporter/SwiftBridging/swift/bridging

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
/// object.doSomething()
7272
/// // The Swift compiler will release object here.
7373
/// ```
74-
#define SWIFT_SHARED_REFERENCE(_retain, _release) \
74+
#define SWIFT_SHARED_REFERENCE(_retain, _release) \
7575
__attribute__((swift_attr("import_reference"))) \
7676
__attribute__((swift_attr(_CXX_INTEROP_STRINGIFY(retain:_retain)))) \
7777
__attribute__((swift_attr(_CXX_INTEROP_STRINGIFY(release:_release))))
@@ -98,18 +98,18 @@
9898
/// let logger = LoggerSingleton.getInstance()
9999
/// logger.log(123)
100100
/// ```
101-
#define SWIFT_IMMORTAL_REFERENCE \
102-
__attribute__((swift_attr("import_reference"))) \
103-
__attribute__((swift_attr(_CXX_INTEROP_STRINGIFY(retain:immortal)))) \
104-
__attribute__((swift_attr(_CXX_INTEROP_STRINGIFY(release:immortal))))
101+
#define SWIFT_IMMORTAL_REFERENCE \
102+
__attribute__((swift_attr("import_reference"))) \
103+
__attribute__((swift_attr("retain:immortal")))) \
104+
__attribute__((swift_attr("release:immortal"))))
105105

106106
/// Specifies that a `class` or `struct` is a reference type whose lifetime
107107
/// is not managed automatically. The programmer must validate that any reference
108108
/// to such object is valid themselves. This annotation lets Swift import such a type as a reference type in Swift.
109-
#define SWIFT_UNSAFE_REFERENCE \
110-
__attribute__((swift_attr("import_reference"))) \
111-
__attribute__((swift_attr(_CXX_INTEROP_STRINGIFY(retain:immortal)))) \
112-
__attribute__((swift_attr(_CXX_INTEROP_STRINGIFY(release:immortal)))) \
109+
#define SWIFT_UNSAFE_REFERENCE \
110+
__attribute__((swift_attr("import_reference"))) \
111+
__attribute__((swift_attr("retain:immortal")))) \
112+
__attribute__((swift_attr("release:immortal")))) \
113113
__attribute__((swift_attr("unsafe")))
114114

115115
/// Specifies a name that will be used in Swift for this declaration instead of its original name.

0 commit comments

Comments
 (0)