@@ -19,8 +19,7 @@ class C {}
1919// noncopyable, nontrivial deinit, pointer aligned
2020// CHECK-64-SAME: <i32 0x81_0007>
2121// CHECK-32-SAME: <i32 0x81_0003>
22- @_moveOnly
23- struct MOStruct {
22+ struct MOStruct: ~Copyable {
2423 var x: Int
2524 var y: C
2625
@@ -32,8 +31,7 @@ struct MOStruct {
3231// noncopyable, enum, nontrivial deinit, pointer aligned
3332// CHECK-64-SAME: <i32 0xA1_0007>
3433// CHECK-32-SAME: <i32 0xA1_0003>
35- @_moveOnly
36- enum MOEnum {
34+ enum MOEnum: ~Copyable {
3735 case x(Int)
3836 case y(C)
3937
@@ -45,8 +43,7 @@ enum MOEnum {
4543// noncopyable, non-inline, nontrivial deinit, pointer aligned
4644// CHECK-64-SAME: <i32 0x83_0007>
4745// CHECK-32-SAME: <i32 0x83_0003>
48- @_moveOnly
49- struct MOComboStruct {
46+ struct MOComboStruct: ~Copyable {
5047 var a: MOStruct
5148 var b: MOEnum
5249 var c: C
@@ -57,8 +54,7 @@ struct MOComboStruct {
5754// noncopyable, enum, nontrivial deinit, pointer aligned
5855// CHECK-64-SAME: <i32 0xA1_0007>
5956// CHECK-32-SAME: <i32 0xA1_0003>
60- @_moveOnly
61- enum MOComboEnum {
57+ enum MOComboEnum: ~Copyable {
6258 case a(MOStruct)
6359 case b(MOEnum)
6460 case c(C)
@@ -71,8 +67,7 @@ enum MOComboEnum {
7167// CHECK-SAME: @__swift_cannot_copy_noncopyable_type
7268// noncopyable, nontrivial deinit, byte aligned
7369// CHECK-SAME: <i32 0x81_0000>
74- @_moveOnly
75- struct MOEmptyStruct {
70+ struct MOEmptyStruct: ~Copyable {
7671 deinit
7772}
7873
@@ -81,8 +76,7 @@ struct MOEmptyStruct {
8176// noncopyable, nontrivial deinit, pointer aligned
8277// CHECK-64-SAME: <i32 0x81_0007>
8378// CHECK-32-SAME: <i32 0x81_0003>
84- @_moveOnly
85- struct MOIntLikeStruct {
79+ struct MOIntLikeStruct: ~Copyable {
8680 var x: Int
8781
8882 deinit
@@ -93,8 +87,7 @@ struct MOIntLikeStruct {
9387// noncopyable, nontrivial deinit, pointer aligned
9488// CHECK-64-SAME: <i32 0x81_0007>
9589// CHECK-32-SAME: <i32 0x81_0003>
96- @_moveOnly
97- struct MOSingleRefcountLikeStruct {
90+ struct MOSingleRefcountLikeStruct: ~Copyable {
9891 var x: C
9992
10093 deinit
@@ -106,17 +99,15 @@ struct MOSingleRefcountLikeStruct {
10699// CHECK-SAME: @__swift_cannot_copy_noncopyable_type
107100// noncopyable, trivial deinit, byte aligned
108101// CHECK-SAME: <i32 0x80_0000>
109- @_moveOnly
110- struct MOEmptyStructNoDeinit {
102+ struct MOEmptyStructNoDeinit: ~Copyable {
111103}
112104
113105// CHECK-LABEL: @{{.*}}23MOIntLikeStructNoDeinitVWV" =
114106// CHECK-SAME: @__swift_cannot_copy_noncopyable_type
115107// noncopyable, trivial deinit, pointer aligned
116108// CHECK-64-SAME: <i32 0x80_0007>
117109// CHECK-32-SAME: <i32 0x80_0003>
118- @_moveOnly
119- struct MOIntLikeStructNoDeinit {
110+ struct MOIntLikeStructNoDeinit: ~Copyable {
120111 var x: Int
121112}
122113
@@ -125,8 +116,7 @@ struct MOIntLikeStructNoDeinit {
125116// noncopyable, nontrivial deinit, pointer aligned
126117// CHECK-64-SAME: <i32 0x81_0007>
127118// CHECK-32-SAME: <i32 0x81_0003>
128- @_moveOnly
129- struct MOSingleRefcountLikeStructNoDeinit {
119+ struct MOSingleRefcountLikeStructNoDeinit: ~Copyable {
130120 var x: C
131121}
132122
@@ -146,8 +136,7 @@ struct MOSingleRefcountLikeStructNoDeinit {
146136
147137// Very large structs will use indirect conventions for their deinit.
148138
149- @_moveOnly
150- struct MOVeryBigStructDeinit {
139+ struct MOVeryBigStructDeinit: ~Copyable {
151140 var x: Int, y: Int, z: Int, w: Int, a: Int, b: Int, c: Int, d: Int
152141
153142 deinit
@@ -158,8 +147,7 @@ struct MOVeryBigStructDeinit {
158147protocol P {}
159148extension Int: P {}
160149
161- @_moveOnly
162- struct MOGenericDeinit<T: P, U> {
150+ struct MOGenericDeinit<T: P, U>: ~Copyable {
163151 var t: T
164152 var u: U
165153
0 commit comments