mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
This changes the order in which declarations are emitted. It also means we no longer emit a vtable entry for the materializeForSet of dynamic storage. Neither of these are intended to have any functional effect.
23 lines
937 B
Swift
23 lines
937 B
Swift
// RUN: %target-swift-frontend %s -import-objc-header %S/Inputs/serialized-objc-header.h -emit-ir -g -o - | %FileCheck %s
|
|
|
|
// REQUIRES: objc_interop
|
|
|
|
protocol Named {
|
|
var name : String { get }
|
|
}
|
|
|
|
// initializer.Person.__allocating_init (initializer.Person.Type)() -> initializer.Person
|
|
// CHECK: define hidden {{.*}}%T11initializer6PersonC* @_T011initializer6PersonCACycfC(%swift.type*{{.*}}) {{.*}} {
|
|
// CHECK: call {{.*}}%T11initializer6PersonC* @_T011initializer6PersonCACycfc(%T11initializer6PersonC* {{.*}}%3), !dbg ![[ALLOCATING_INIT:.*]]
|
|
|
|
// initializer.Person.init (initializer.Person.Type)() -> initializer.Person
|
|
// CHECK: define hidden {{.*}}%T11initializer6PersonC* @_T011initializer6PersonCACycfc(%T11initializer6PersonC*{{.*}}) {{.*}} {
|
|
|
|
// CHECK-DAG: ![[ALLOCATING_INIT]] = !DILocation(line: 0, scope
|
|
class Person : Named {
|
|
var name : String { get { return "No Name" } }
|
|
var age = 0
|
|
}
|
|
|
|
var person = Person()
|