|
1 | 1 | // REQUIRES: swift_feature_SafeInteropWrappers |
2 | 2 | // REQUIRES: swift_feature_LifetimeDependence |
3 | 3 |
|
4 | | -// RUN: %target-swift-ide-test -print-module -module-to-print=CountedByNoEscapeClang -plugin-path %swift-plugin-dir -I %S/Inputs -source-filename=x -enable-experimental-feature SafeInteropWrappers -enable-experimental-feature LifetimeDependence | %FileCheck %s |
| 4 | +// RUN: %target-swift-ide-test -print-module -module-to-print=CountedByNoEscapeClang -plugin-path %swift-plugin-dir -I %S/Inputs -source-filename=x -enable-experimental-feature SafeInteropWrappers -enable-experimental-feature LifetimeDependence -Xcc -Wno-nullability-completeness | %FileCheck %s |
5 | 5 |
|
6 | 6 | // swift-ide-test doesn't currently typecheck the macro expansions, so run the compiler as well |
7 | 7 | // RUN: %empty-directory(%t) |
8 | | -// RUN: %target-swift-frontend -emit-module -plugin-path %swift-plugin-dir -o %t/CountedByNoEscape.swiftmodule -I %S/Inputs -enable-experimental-feature SafeInteropWrappers -enable-experimental-feature LifetimeDependence %s |
| 8 | +// RUN: %target-swift-frontend -emit-module -plugin-path %swift-plugin-dir -o %t/CountedByNoEscape.swiftmodule -I %S/Inputs -enable-experimental-feature SafeInteropWrappers -enable-experimental-feature LifetimeDependence -strict-memory-safety -warnings-as-errors -Xcc -Werror -Xcc -Wno-nullability-completeness %s |
9 | 9 |
|
10 | 10 | // Check that ClangImporter correctly infers and expands @_SwiftifyImport macros for functions with __counted_by __noescape parameters. |
11 | 11 |
|
@@ -150,14 +150,14 @@ public func callNullable(_ p: inout MutableSpan<CInt>?) { |
150 | 150 | @lifetime(p: copy p) |
151 | 151 | @inlinable |
152 | 152 | public func callReturnLifetimeBound(_ p: inout MutableSpan<CInt>) { |
153 | | - let a: MutableSpan<CInt> = returnLifetimeBound(2, &p) |
| 153 | + let _: MutableSpan<CInt> = returnLifetimeBound(2, &p) |
154 | 154 | } |
155 | 155 |
|
156 | 156 | @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *) |
157 | 157 | @inlinable |
158 | 158 | public func callReturnPointer() { |
159 | | - let a: UnsafeMutableBufferPointer<CInt>? = returnPointer(4) // call wrapper |
160 | | - let b: UnsafeMutablePointer<CInt>? = returnPointer(4) // call unsafe interop |
| 159 | + let _: UnsafeMutableBufferPointer<CInt>? = returnPointer(4) // call wrapper |
| 160 | + let _: UnsafeMutablePointer<CInt>? = returnPointer(4) // call unsafe interop |
161 | 161 | } |
162 | 162 |
|
163 | 163 | @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *) |
@@ -207,7 +207,7 @@ public func callFunc(_ p: inout MutableSpan<CInt>?) { |
207 | 207 | @lifetime(p: copy p) |
208 | 208 | @inlinable |
209 | 209 | public func callFuncRenameKeyword(_ p: inout MutableSpan<CInt>?) { |
210 | | - funcRenamed(func: &p, extension: 1, init: 2, open: 3, var: 4, is: 5, as: 6, in: 7, guard: 8, where: 9) |
| 210 | + let _ = funcRenamed(func: &p, extension: 1, init: 2, open: 3, var: 4, is: 5, as: 6, in: 7, guard: 8, where: 9) |
211 | 211 | } |
212 | 212 |
|
213 | 213 | @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *) |
|
0 commit comments