Files
swift-mirror/test/Serialization/basic_sil_objc.swift
Michael Gottesman be568902f2 [ownership] Always print out ownership argument annotations whether or not -enable-sil-ownership is passed in.
This is how we originally controlled whether or not we printed out ownership
annotations when we printed SIL. Since then, I have changed (a few months ago I
believe) the ownership model eliminator to know how to eliminate these
annotations from the SIL itself. So this hack can be removed.

As an additional benefit, this will let me rename -enable-sil-ownership to
-enable-sil-ownership-verifier. This will I hope eliminate confusion around this
option in the short term while I am preparing to work on semantic sil again.

rdar://42509812
2018-07-24 13:18:37 -07:00

20 lines
865 B
Swift

// RUN: %empty-directory(%t)
// RUN: %target-build-swift -Xfrontend %clang-importer-sdk -I %S/../Inputs/clang-importer-sdk/swift-modules -emit-module -Xfrontend -disable-diagnostic-passes -force-single-frontend-invocation -o %t/def_basic_objc.swiftmodule %S/Inputs/def_basic_objc.sil
// RUN: llvm-bcanalyzer %t/def_basic_objc.swiftmodule | %FileCheck %s
// RUN: %target-build-swift -Xfrontend %clang-importer-sdk -emit-sil -I %t %s -o %t/basic_sil_objc.sil
// RUN: %target-sil-opt -assume-parsing-unqualified-ownership-sil %t/basic_sil_objc.sil -performance-linker -I %t | %FileCheck %S/Inputs/def_basic_objc.sil
// This test currently is written such that no optimizations are assumed.
// REQUIRES: swift_test_mode_optimize_none
// REQUIRES: objc_interop
// CHECK-NOT: UnknownCode
import def_basic_objc
import Foundation
func test_all() {
serialize_all()
}