Files
swift-mirror/test/DebugInfo/LoadableByAddress.swift
Max Desiatov 0f1dce4d1b test/DebugInfo/LoadableByAddress.swift: require PTRSIZE=64 (#86774)
This test in its current form does not pass on 32-bit platforms.
2026-01-25 08:47:34 -08:00

30 lines
696 B
Swift

// RUN: %target-swift-frontend %s -module-name A -emit-ir -g -o - | %FileCheck %s
// REQUIRES: PTRSIZE=64
public struct Continuation<A> {
private let magicToken = "Hello World"
fileprivate let f: (() -> A)?
private let _makeMeBigger = 0
public func run() {}
}
public typealias ContinuationU = Continuation<()>
// CHECK: %2 = alloca %T1A12ContinuationV, align 8
// CHECK-NEXT: #dbg_declare(ptr %2,
// CHECK-SAME: ![[X:.*]], !DIExpression()
// CHECK: ![[X]] = !DILocalVariable(name: "$element",
// CHECK: !DILocalVariable(name: "x",
public func f<A>(_ xs: [Continuation<A>]) -> (() -> A?) {
return {
for x in xs {
x.run()
}
return nil
}
}