Files
swift-mirror/test/SILOptimizer/dead_internal_func.swift
2016-08-10 23:52:02 -07:00

14 lines
454 B
Swift

// RUN: %target-swift-frontend -O -emit-sil %s %S/Inputs/internal_func.swift | %FileCheck %s
// RUN: %target-swift-frontend -O -enable-testing -emit-sil %s %S/Inputs/internal_func.swift | %FileCheck -check-prefix=CHECK-TESTABLE %s
// Check that an internal function from another file is removed after it gets
// dead through inlining.
// CHECK-NOT: sil {{.*}}testfunc
// CHECK-TESTABLE: sil {{.*}}testfunc
public func caller_func() {
testfunc()
}