blob: 01c6d32fe05b911fa94a7c4c83fe6787718826f2 [file] [log] [blame]
// RUN: %target-swift-frontend -emit-ir %s -module-name Test | FileCheck %s
import Builtin
struct X {
init()
var x : Builtin.Int32
}
// Make sure we can irgen a SIL function with various parameter attributes
// without choking. This is just a basic reality check.
// CHECK: define{{( protected)?}} void @foo(%V4Test1X* noalias nocapture sret, %V4Test1X* noalias nocapture dereferenceable({{.*}}), %V4Test1X* nocapture dereferenceable({{.*}}), %V4Test1X* noalias nocapture dereferenceable({{.*}}), i32, i32, i32, i32) {{.*}} {
sil @foo : $@convention(thin) (@in X, @inout X, @in_guaranteed X, @owned X, X, @guaranteed X, @deallocating X) -> @out X {
bb0(%0 : $*X, %1 : $*X, %2 : $*X, %3 : $*X, %4 : $X, %5 : $X, %6 : $X, %7 : $X):
%9999 = tuple()
return %9999 : $()
}