mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Update tests for Span back-deployment
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
void simple(int len, int * __counted_by(len) __noescape p);
|
||||
|
||||
void swiftAttr(int len, int *p) __attribute__((
|
||||
swift_attr("@_SwiftifyImport(.countedBy(pointer: .param(2), count: \"len\"), .nonescaping(pointer: .param(2)), spanAvailability: \"visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4\")")));
|
||||
swift_attr("@_SwiftifyImport(.countedBy(pointer: .param(2), count: \"len\"), .nonescaping(pointer: .param(2)), spanAvailability: \"visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4\")")));
|
||||
|
||||
void shared(int len, int * __counted_by(len) __noescape p1, int * __counted_by(len) __noescape p2);
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
void simple(int len, const void * __sized_by(len) __noescape p);
|
||||
|
||||
void swiftAttr(int len, const void *p) __attribute__((swift_attr(
|
||||
"@_SwiftifyImport(.sizedBy(pointer: .param(2), size: \"len\"), .nonescaping(pointer: .param(2)), spanAvailability: \"visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4\")")));
|
||||
"@_SwiftifyImport(.sizedBy(pointer: .param(2), size: \"len\"), .nonescaping(pointer: .param(2)), spanAvailability: \"visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4\")")));
|
||||
|
||||
void shared(int len, const void * __sized_by(len) __noescape p1, const void * __sized_by(len) __noescape p2);
|
||||
|
||||
|
||||
@@ -12,96 +12,96 @@
|
||||
import CountedByLifetimeboundClang
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func complexExpr(_ len: Int32, _ offset: Int32, _ p: inout MutableSpan<Int32>) -> MutableSpan<Int32>
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func constant(_ p: inout MutableSpan<Int32>?) -> MutableSpan<Int32>?
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(borrow p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func noncountedLifetime(_ len: Int32, _ p: UnsafeMutablePointer<Int32>!) -> MutableSpan<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nonnull(_ len: Int32, _ p: inout MutableSpan<Int32>) -> MutableSpan<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullUnspecified(_ len: Int32, _ p: inout MutableSpan<Int32>) -> MutableSpan<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullable(_ len: Int32, _ p: inout MutableSpan<Int32>?) -> MutableSpan<Int32>?
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func shared(_ p: inout MutableSpan<Int32>) -> MutableSpan<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func simple(_ len: Int32, _ p: inout MutableSpan<Int32>) -> MutableSpan<Int32>
|
||||
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callComplexExpr(_ p: inout MutableSpan<CInt>) {
|
||||
let _: MutableSpan<CInt> = complexExpr(73, 37, &p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNonnull(_ p: inout MutableSpan<CInt>) {
|
||||
let _: MutableSpan<CInt> = nonnull(73, &p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNullUnspecified(_ p: inout MutableSpan<CInt>) {
|
||||
let _: MutableSpan<CInt> = nullUnspecified(73, &p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNullable(_ p: inout MutableSpan<CInt>?) {
|
||||
let _: MutableSpan<CInt> = nullable(73, &p)!
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callShared(_ p: inout MutableSpan<CInt>) {
|
||||
let _: MutableSpan<CInt> = shared(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callSimple(_ p: inout MutableSpan<CInt>) {
|
||||
let _: MutableSpan<CInt> = simple(73, &p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNoncountedLifetime(_ p: UnsafeMutablePointer<CInt>) {
|
||||
let _: MutableSpan<CInt> = unsafe noncountedLifetime(73, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callConstant(_ p: inout MutableSpan<CInt>?) {
|
||||
let _: MutableSpan<CInt>? = constant(&p)
|
||||
|
||||
@@ -12,89 +12,89 @@
|
||||
import CountedByNoEscapeClang
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_anonymous_param1: copy _anonymous_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func anonymous(_ _anonymous_param1: inout MutableSpan<Int32>?)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(func: copy func)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func clash(func: inout MutableSpan<Int32>?, clash where: Int32)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_clash2_param1: copy _clash2_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func clash2(func _clash2_param1: inout MutableSpan<Int32>?, clash2 _clash2_param2: Int32)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func complexExpr(_ len: Int32, _ offset: Int32, _ p: inout MutableSpan<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_func_param1: copy _func_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func `func`(_ _func_param1: inout MutableSpan<Int32>?)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(borrow extension)
|
||||
// CHECK-NEXT: @_lifetime(func: copy func)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func funcRenamed(func: inout MutableSpan<Int32>?, extension: Int32, init: Int32, open: Int32, var: Int32, is: Int32, as: Int32, in: Int32, guard: Int32, where: Int32) -> UnsafeMutableRawPointer!
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(borrow _funcRenamedAnon_param2)
|
||||
// CHECK-NEXT: @_lifetime(_funcRenamedAnon_param1: copy _funcRenamedAnon_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func funcRenamedAnon(func _funcRenamedAnon_param1: inout MutableSpan<Int32>?, extension _funcRenamedAnon_param2: Int32, init _funcRenamedAnon_param3: Int32, open _funcRenamedAnon_param4: Int32, var _funcRenamedAnon_param5: Int32, is _funcRenamedAnon_param6: Int32, as _funcRenamedAnon_param7: Int32, in _funcRenamedAnon_param8: Int32, guard _funcRenamedAnon_param9: Int32, where _funcRenamedAnon_param10: Int32) -> UnsafeMutableRawPointer!
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_in_param1: copy _in_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func `in`(func _in_param1: inout MutableSpan<Int32>?, in _in_param2: Int32)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(func: copy func)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func keyword(_ func: inout MutableSpan<Int32>?, _ extension: Int32, _ init: Int32, _ open: Int32, _ var: Int32, _ is: Int32, _ as: Int32, _ in: Int32, _ guard: Int32, _ where: Int32)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func keywordType(_ p: inout MutableSpan<actor?>, _ p2: actor) -> actor
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_lenName_param2: copy _lenName_param2)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func lenName(_ _lenName_param0: Int32, _ _lenName_param1: Int32, _ _lenName_param2: inout MutableSpan<Int32>?)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nonnull(_ p: inout MutableSpan<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullUnspecified(_ p: inout MutableSpan<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullable(_ p: inout MutableSpan<Int32>?)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(func: copy func)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func open(func: inout MutableSpan<Int32>?, open where: Int32)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_pointerName_param1: copy _pointerName_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func pointerName(_ _pointerName_param1: inout MutableSpan<Int32>?)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func returnLifetimeBound(_ len1: Int32, _ p: inout MutableSpan<Int32>) -> MutableSpan<Int32>
|
||||
@@ -103,64 +103,64 @@ import CountedByNoEscapeClang
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func returnPointer(_ len: Int32) -> UnsafeMutableBufferPointer<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p1: copy p1)
|
||||
// CHECK-NEXT: @_lifetime(p2: copy p2)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func shared(_ p1: inout MutableSpan<Int32>, _ p2: inout MutableSpan<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func simple(_ p: inout MutableSpan<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func swiftAttr(_ p: inout MutableSpan<Int32>)
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callComplexExpr(_ p: inout MutableSpan<CInt>) {
|
||||
complexExpr(CInt(p.count), 1, &p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callNonnull(_ p: inout MutableSpan<CInt>) {
|
||||
nonnull(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callNullUnspecified(_ p: inout MutableSpan<CInt>) {
|
||||
nullUnspecified(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callNullable(_ p: inout MutableSpan<CInt>?) {
|
||||
nullable(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callReturnLifetimeBound(_ p: inout MutableSpan<CInt>) {
|
||||
let _: MutableSpan<CInt> = returnLifetimeBound(2, &p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callReturnPointer() {
|
||||
let _: UnsafeMutableBufferPointer<CInt>? = returnPointer(4) // call wrapper
|
||||
let _: UnsafeMutablePointer<CInt>? = returnPointer(4) // call unsafe interop
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@_lifetime(p2: copy p2)
|
||||
@inlinable
|
||||
@@ -168,77 +168,77 @@ public func callShared(_ p: inout MutableSpan<CInt>, _ p2: inout MutableSpan<CIn
|
||||
shared(&p, &p2)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callSimple(_ p: inout MutableSpan<CInt>) {
|
||||
simple(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callSwiftAttr(_ p: inout MutableSpan<CInt>) {
|
||||
swiftAttr(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callAnonymous(_ p: inout MutableSpan<CInt>?) {
|
||||
anonymous(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callKeyword(_ p: inout MutableSpan<CInt>?) {
|
||||
keyword(&p, 1, 2, 3, 4, 5, 6, 7, 8, 9)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callFunc(_ p: inout MutableSpan<CInt>?) {
|
||||
`func`(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callFuncRenameKeyword(_ p: inout MutableSpan<CInt>?) {
|
||||
let _ = funcRenamed(func: &p, extension: 1, init: 2, open: 3, var: 4, is: 5, as: 6, in: 7, guard: 8, where: 9)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callFuncRenameClash(_ p: inout MutableSpan<CInt>?) {
|
||||
clash(func: &p, clash: 1)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callFuncRenameClashKeyword(_ p: inout MutableSpan<CInt>?) {
|
||||
`open`(func: &p, open: 1)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callFuncRenameClashKeywordAnon(_ p: inout MutableSpan<CInt>?) {
|
||||
`in`(func: &p, in: 1)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callPointerName(_ p: inout MutableSpan<CInt>?) {
|
||||
pointerName(&p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@_lifetime(p: copy p)
|
||||
@inlinable
|
||||
public func callLenName(_ p: inout MutableSpan<CInt>?) {
|
||||
|
||||
@@ -12,106 +12,106 @@
|
||||
import SizedByLifetimeboundClang
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy _bytesized_param1)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func bytesized(_ _bytesized_param1: RawSpan) -> MutableRawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy _charsized_param0)
|
||||
// CHECK-NEXT: @_lifetime(_charsized_param0: copy _charsized_param0)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func charsized(_ _charsized_param0: inout MutableRawSpan) -> MutableRawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func complexExpr(_ len: Int32, _ offset: Int32, _ p: RawSpan) -> RawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nonnull(_ len: Int32, _ p: RawSpan) -> RawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(borrow p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nonsizedLifetime(_ len: Int32, _ p: UnsafeRawPointer!) -> RawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullUnspecified(_ len: Int32, _ p: RawSpan) -> RawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullable(_ len: Int32, _ p: RawSpan?) -> RawSpan?
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func opaque(_ len: Int32, _ p: RawSpan) -> RawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func shared(_ p: RawSpan) -> RawSpan
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func simple(_ len: Int32, _ p: RawSpan) -> RawSpan
|
||||
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callComplexExpr(_ p: RawSpan) {
|
||||
let _: RawSpan = complexExpr(73, 37, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNonnull(_ p: RawSpan) {
|
||||
let _: RawSpan = nonnull(73, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNullUnspecified(_ p: RawSpan) {
|
||||
let _: RawSpan = nullUnspecified(73, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNullable(_ p: RawSpan?) {
|
||||
let _: RawSpan = nullable(73, p)!
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callShared(_ p: RawSpan) {
|
||||
let _: RawSpan = shared(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callSimple(_ p: RawSpan) {
|
||||
let _: RawSpan = simple(73, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNonsizedLifetime(_ p: UnsafeRawPointer) {
|
||||
let _: RawSpan = unsafe nonsizedLifetime(73, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callBytesized(_ p: RawSpan) {
|
||||
let _: MutableRawSpan = bytesized(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
@_lifetime(p: copy p)
|
||||
public func callCharsized(_ p: inout MutableRawSpan) {
|
||||
|
||||
@@ -12,105 +12,105 @@ import SizedByNoEscapeClang
|
||||
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func bytesized(_ _bytesized_param1: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(_charsized_param0: copy _charsized_param0)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func charsized(_ _charsized_param0: inout MutableRawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func complexExpr(_ len: Int{{.*}}, _ offset: Int{{.*}}, _ p: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nonnull(_ p: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullUnspecified(_ p: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func nullable(_ p: RawSpan?)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func opaque(_ p: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func returnPointer(_ len: Int{{.*}}) -> UnsafeRawBufferPointer
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func shared(_ p1: RawSpan, _ p2: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func simple(_ p: RawSpan)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func swiftAttr(_ p: RawSpan)
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callComplexExpr(_ p: RawSpan) {
|
||||
complexExpr(CInt(p.byteCount), 1, p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNonnull(_ p: RawSpan) {
|
||||
nonnull(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNullUnspecified(_ p: RawSpan) {
|
||||
nullUnspecified(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callNullable(_ p: RawSpan?) {
|
||||
nullable(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callReturnPointer() {
|
||||
let _: UnsafeRawBufferPointer? = returnPointer(4) // call wrapper
|
||||
let _: UnsafeRawPointer? = returnPointer(4) // call unsafe interop
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callShared(_ p: RawSpan, _ p2: RawSpan) {
|
||||
shared(p, p2)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callSimple(_ p: RawSpan) {
|
||||
simple(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callSwiftAttr(_ p: RawSpan) {
|
||||
swiftAttr(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
public func callBytesized(_ p: RawSpan) {
|
||||
bytesized(p)
|
||||
}
|
||||
|
||||
@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
@inlinable
|
||||
@_lifetime(p: copy p)
|
||||
public func callCharsized(_ p: inout MutableRawSpan) {
|
||||
|
||||
@@ -28,7 +28,7 @@ import CxxStdlib
|
||||
// CHECK: struct X {
|
||||
// CHECK-NEXT: init()
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public mutating func methodWithSafeWrapper(_ s: Span<CInt>)
|
||||
// CHECK-NEXT: mutating func methodWithSafeWrapper(_ s: ConstSpanOfInt)
|
||||
// CHECK-NEXT: }
|
||||
@@ -41,45 +41,45 @@ import CxxStdlib
|
||||
// CHECK-NEXT: }
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(s: copy s)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func FuncWithMutableSafeWrapper(_ s: inout MutableSpan<CInt>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy s)
|
||||
// CHECK-NEXT: @_lifetime(s: copy s)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func FuncWithMutableSafeWrapper2(_ s: inout MutableSpan<CInt>) -> MutableSpan<CInt>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(&v)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func FuncWithMutableSafeWrapper3(_ v: inout VecOfInt) -> MutableSpan<CInt>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func MixedFuncWithMutableSafeWrapper1(_ p: inout MutableSpan<Int32>) -> MutableSpan<CInt>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(&v)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func MixedFuncWithMutableSafeWrapper2(_ v: inout VecOfInt, _ len: Int32) -> MutableSpan<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(s: copy s)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func MixedFuncWithMutableSafeWrapper3(_ s: inout MutableSpan<CInt>, _ p: UnsafeMutableBufferPointer<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(s: copy s)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func MixedFuncWithMutableSafeWrapper4(_ s: inout MutableSpan<CInt>, _ p: inout MutableSpan<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(p: copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func MixedFuncWithMutableSafeWrapper5(_ s: SpanOfInt, _ p: inout MutableSpan<Int32>)
|
||||
|
||||
@@ -90,43 +90,43 @@ import CxxStdlib
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func MixedFuncWithMutableSafeWrapper7(_ p: UnsafeMutableBufferPointer<Int32>) -> SpanOfInt
|
||||
|
||||
// CHECK: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func `func`(_ copy: Span<CInt>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func funcWithSafeWrapper(_ s: Span<CInt>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy s)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func funcWithSafeWrapper2(_ s: Span<CInt>) -> Span<CInt>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(borrow v)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func funcWithSafeWrapper3(_ v: borrowing VecOfInt) -> Span<CInt>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy p)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mixedFuncWithSafeWrapper1(_ p: Span<Int32>) -> Span<CInt>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(borrow v)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mixedFuncWithSafeWrapper2(_ v: borrowing VecOfInt, _ len: Int32) -> Span<Int32>
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mixedFuncWithSafeWrapper3(_ s: Span<CInt>, _ p: UnsafeMutableBufferPointer<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mixedFuncWithSafeWrapper4(_ s: Span<CInt>, _ p: Span<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mixedFuncWithSafeWrapper5(_ s: ConstSpanOfInt, _ p: Span<Int32>)
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
@@ -136,7 +136,7 @@ import CxxStdlib
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mixedFuncWithSafeWrapper7(_ p: UnsafeBufferPointer<Int32>) -> ConstSpanOfInt
|
||||
|
||||
// CHECK-NEXT: /// This is an auto-generated wrapper for safer interop
|
||||
// CHECK-NEXT: @available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: @_lifetime(copy: copy copy)
|
||||
// CHECK-NEXT: @_alwaysEmitIntoClient @_disfavoredOverload public func mutableKeyword(_ copy: inout MutableSpan<CInt>)
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ func test(_ s: Span<CInt>) {
|
||||
// CHECK: This comment contains `markup`.
|
||||
// CHECK: - And a list
|
||||
// CHECK-LABEL: DOC COMMENT XML
|
||||
// CHECK: <Function file="@__swiftmacro_So9testCDecl15_SwiftifyImportfMp_.swift" line="6" column="134"><Name>testCDecl(_:)</Name><USR>s:SC9testCDeclyys4SpanVys5Int32VGF</USR><Declaration>@available(visionOS 1.1, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK: <Function file="@__swiftmacro_So9testCDecl15_SwiftifyImportfMp_.swift" line="6" column="134"><Name>testCDecl(_:)</Name><USR>s:SC9testCDeclyys4SpanVys5Int32VGF</USR><Declaration>@available(visionOS 1.0, tvOS 12.2, watchOS 5.2, iOS 12.2, macOS 10.14.4, *)
|
||||
// CHECK-NEXT: public func testCDecl(_ p: Span<Int32>)</Declaration><CommentParts><Abstract><Para>This comment contains <codeVoice>markup</codeVoice>. *</Para></Abstract><Discussion><List-Bullet><Item><List-Bullet><Item><Para>And a list</Para></Item></List-Bullet></Item></List-Bullet><Para>This is an auto-generated wrapper for safer interop</Para></Discussion></CommentParts></Function>
|
||||
|
||||
// CHECK-LABEL: SYMBOL GRAPH BEGIN
|
||||
|
||||
Reference in New Issue
Block a user