mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
This gives big code size wins for unused types and also for types, which are never used in a generic context. Also it reduces the amount of symbols in the symbol table. The size wins heavily depend on the project. I have seen binary size reductions from 0 to 20% on real world projects. rdar://problem/30119960
15 lines
388 B
Swift
15 lines
388 B
Swift
// RUN: %target-swift-frontend(mock-sdk: %clang-importer-sdk) -emit-ir -primary-file %s -import-objc-header %S/Inputs/objc_bridged_generic_conformance.h | %FileCheck %s
|
|
// REQUIRES: objc_interop
|
|
|
|
// CHECK-NOT: _TMnCSo
|
|
|
|
// CHECK: @"\01l_protocol_conformances" = {{.*}} @"got.OBJC_CLASS_$_Thingy"
|
|
|
|
// CHECK-NOT: _TMnCSo
|
|
|
|
protocol P { func test() }
|
|
|
|
extension Thingy: P {
|
|
func test() {}
|
|
}
|