mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Fix the common error of using underscores instead of dashes. In the rebranch this is an error (lit got more picky), but it also makes sense to fix the tests in the main branch
27 lines
617 B
Plaintext
27 lines
617 B
Plaintext
// RUN: %target-sil-opt %s | %FileCheck %s
|
|
|
|
import Swift
|
|
|
|
// CHECK: @_hasStorage var orgx
|
|
class Rect {
|
|
@_hasStorage var orgx: Double { get }
|
|
init(orgx: Double)
|
|
}
|
|
|
|
// CHECK-LABEL: sil @_TFC4rect4Rectg4orgxSd
|
|
sil @_TFC4rect4Rectg4orgxSd : $@convention(method) (@guaranteed Rect) -> Double {
|
|
bb0(%0 : $Rect):
|
|
debug_value %0 : $Rect
|
|
// CHECK: ref_element_addr
|
|
%2 = ref_element_addr %0 : $Rect, #Rect.orgx
|
|
%3 = load %2 : $*Double
|
|
strong_release %0 : $Rect
|
|
return %3 : $Double
|
|
}
|
|
|
|
// CHECK-LABEL: sil_vtable Rect
|
|
sil_vtable Rect {
|
|
// CHECK: #Rect.orgx!getter
|
|
#Rect.orgx!getter: @_TFC4rect4Rectg4orgxSd
|
|
}
|