@@ -23,11 +23,6 @@ entry:
23
23
br body(%lifetime : $X, %value_1 : $X)
24
24
25
25
body(%reborrow : @guaranteed $X, %value_2 : @owned $X):
26
- // TODO: The copy is currently needed to trigger canonicalization of the
27
- // lifetime. Remove once it is no longer needed.
28
- %copy = copy_value %value_2 : $X
29
- destroy_value %copy : $X
30
-
31
26
end_borrow %reborrow : $X
32
27
destroy_value %value_2 : $X
33
28
br exit
@@ -50,11 +45,6 @@ entry(%unrelated : @guaranteed $X):
50
45
br body(%borrow_1 : $X, %value_1 : $X)
51
46
52
47
body(%borrow_2 : @guaranteed $X, %value_2 : @owned $X):
53
- // TODO: The copy is currently needed to trigger canonicalization of the
54
- // lifetime. Remove once it is no longer needed.
55
- %copy = copy_value %value_2 : $X
56
- destroy_value %copy : $X
57
-
58
48
%hold = function_ref @holdX : $@convention(thin) (@guaranteed X) -> ()
59
49
apply %hold(%borrow_2) : $@convention(thin) (@guaranteed X) -> ()
60
50
end_borrow %borrow_2 : $X
@@ -83,10 +73,6 @@ body1(%lifetime_2 : @guaranteed $X, %value_2 : @owned $X):
83
73
br body2(%lifetime_2 : $X, %value_2 : $X)
84
74
85
75
body2(%lifetime_3 : @guaranteed $X, %value_3 : @owned $X):
86
- // TODO: Remove the copy once it isn't necessary to trigger canonicalization.
87
- %copy_3 = copy_value %value_3 : $X
88
- destroy_value %copy_3 : $X
89
-
90
76
end_borrow %lifetime_3 : $X
91
77
destroy_value %value_3 : $X
92
78
br exit
@@ -113,10 +99,6 @@ body1(%borrow_2 : @guaranteed $X, %value_2 : @owned $X):
113
99
br body2(%borrow_2 : $X, %value_2 : $X)
114
100
115
101
body2(%borrow_3 : @guaranteed $X, %value_3 : @owned $X):
116
- // TODO: Remove the copy once it isn't necessary to trigger canonicalization.
117
- %copy_3 = copy_value %value_3 : $X
118
- destroy_value %copy_3 : $X
119
-
120
102
%hold = function_ref @holdX : $@convention(thin) (@guaranteed X) -> ()
121
103
apply %hold(%borrow_3) : $@convention(thin) (@guaranteed X) -> ()
122
104
end_borrow %borrow_3 : $X
@@ -144,10 +126,6 @@ body1(%value_2 : @owned $X):
144
126
br body2(%lifetime_2 : $X, %value_2 : $X)
145
127
146
128
body2(%lifetime_3 : @guaranteed $X, %value_3 : @owned $X):
147
- // TODO: Remove the copy once it isn't necessary to trigger canonicalization.
148
- %copy_3 = copy_value %value_3 : $X
149
- destroy_value %copy_3 : $X
150
-
151
129
end_borrow %lifetime_3 : $X
152
130
destroy_value %value_3 : $X
153
131
br exit
@@ -180,11 +158,6 @@ body:
180
158
%get = function_ref @getX : $@convention(thin) () -> (@owned X)
181
159
%value_0 = apply %get() : $@convention(thin) () -> (@owned X)
182
160
end_borrow %reborrow : $FakeOptional<X>
183
-
184
- // TODO: Remove the copy once it isn't necessary to trigger canonicalization.
185
- %bogus = copy_value %value : $FakeOptional<X>
186
- destroy_value %bogus : $FakeOptional<X>
187
-
188
161
destroy_value %value : $FakeOptional<X>
189
162
%some_value_0 = enum $FakeOptional<X>, #FakeOptional.some!enumelt, %value_0 : $X
190
163
%some_borrow_0 = begin_borrow %some_value_0 : $FakeOptional<X>
244
217
br bb1(%8 : $X, %9 : $X)
245
218
246
219
bb10:
247
- // TODO: Remove the copy once it isn't necessary to trigger canonicalization.
248
- %bogus = copy_value %4 : $X
249
- destroy_value %bogus : $X
250
220
%23 = tuple ()
251
221
end_borrow %3 : $X
252
222
destroy_value %4 : $X
@@ -269,8 +239,6 @@ reborrow_only(%lifetime_3 : @guaranteed $X):
269
239
br exit
270
240
271
241
exit:
272
- %bogus = copy_value %value_2 : $X
273
- destroy_value %bogus : $X
274
242
%retval = tuple ()
275
243
end_borrow %lifetime_3 : $X
276
244
destroy_value %value_2 : $X
@@ -296,8 +264,6 @@ reborrow_only_2(%lifetime_4 : @guaranteed $X):
296
264
br exit
297
265
298
266
exit:
299
- %bogus = copy_value %value_2 : $X
300
- destroy_value %bogus : $X
301
267
%retval = tuple ()
302
268
end_borrow %lifetime_4 : $X
303
269
destroy_value %value_2 : $X
0 commit comments