Skip to content

Commit 901404f

Browse files
committed
[5.0-adjustment] Add @trivial to two trivial arguments. This has been obviated on master.
1 parent 06152d2 commit 901404f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/SILGen/switch.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1151,7 +1151,7 @@ func address_only_with_nontrivial_subtype(_ a: NonTrivialSingleCaseEnum, _ value
11511151
// and partially an object that even though we access the object at +0 via a
11521152
// load_borrow, we do not lose the +1 from the original tuple formation.
11531153
// CHECK-LABEL: sil hidden @$s6switch35partial_address_only_tuple_dispatchyyAA5KlassC_ypSgtF : $@convention(thin) (@guaranteed Klass, @in_guaranteed Optional<Any>) -> () {
1154-
// CHECK: bb0([[ARG0:%.*]] : @guaranteed $Klass, [[ARG1:%.*]] : $*Optional<Any>):
1154+
// CHECK: bb0([[ARG0:%.*]] : @guaranteed $Klass, [[ARG1:%.*]] : @trivial $*Optional<Any>):
11551155
// CHECK: [[ARG0_COPY:%.*]] = copy_value [[ARG0]]
11561156
// CHECK: [[ARG1_COPY:%.*]] = alloc_stack $Optional<Any>
11571157
// CHECK: copy_addr [[ARG1]] to [initialization] [[ARG1_COPY]]
@@ -1183,7 +1183,7 @@ func partial_address_only_tuple_dispatch(_ name: Klass, _ value: Any?) {
11831183
}
11841184

11851185
// CHECK-LABEL: sil hidden @$s6switch50partial_address_only_tuple_dispatch_with_fail_caseyyAA5KlassC_ypSgtF : $@convention(thin) (@guaranteed Klass, @in_guaranteed Optional<Any>) -> () {
1186-
// CHECK: bb0([[ARG0:%.*]] : @guaranteed $Klass, [[ARG1:%.*]] : $*Optional<Any>):
1186+
// CHECK: bb0([[ARG0:%.*]] : @guaranteed $Klass, [[ARG1:%.*]] : @trivial $*Optional<Any>):
11871187
// CHECK: [[ARG0_COPY:%.*]] = copy_value [[ARG0]]
11881188
// CHECK: [[ARG1_COPY:%.*]] = alloc_stack $Optional<Any>
11891189
// CHECK: copy_addr [[ARG1]] to [initialization] [[ARG1_COPY]]

0 commit comments

Comments
 (0)