mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Calls to getters are implicit because the compiler inserts them on a property access, but the location is useful in backtraces so it should be preserved. rdar://109123395
11 lines
384 B
Swift
11 lines
384 B
Swift
// RUN: %target-swift-frontend %s -Onone -emit-ir -g -o - -parse-as-library -module-name a | %FileCheck %s
|
|
func use<T>(_ t : T) {}
|
|
public func f() -> (() -> ()) {
|
|
lazy var i : Int = 0
|
|
return {
|
|
// CHECK: call {{.*}} @"$s1a1fyycyF1iL_Sivg"({{.*}}), !dbg ![[GETTER_LOC:[0-9]+]]
|
|
// CHECK: ![[GETTER_LOC]] = !DILocation(line: [[@LINE+1]], column: 11
|
|
use(i)
|
|
}
|
|
}
|