@@ -23,11 +23,6 @@ entry:
2323 br body(%lifetime : $X, %value_1 : $X)
2424
2525body(%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-
3126 end_borrow %reborrow : $X
3227 destroy_value %value_2 : $X
3328 br exit
@@ -50,11 +45,6 @@ entry(%unrelated : @guaranteed $X):
5045 br body(%borrow_1 : $X, %value_1 : $X)
5146
5247body(%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-
5848 %hold = function_ref @holdX : $@convention(thin) (@guaranteed X) -> ()
5949 apply %hold(%borrow_2) : $@convention(thin) (@guaranteed X) -> ()
6050 end_borrow %borrow_2 : $X
@@ -83,10 +73,6 @@ body1(%lifetime_2 : @guaranteed $X, %value_2 : @owned $X):
8373 br body2(%lifetime_2 : $X, %value_2 : $X)
8474
8575body2(%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-
9076 end_borrow %lifetime_3 : $X
9177 destroy_value %value_3 : $X
9278 br exit
@@ -113,10 +99,6 @@ body1(%borrow_2 : @guaranteed $X, %value_2 : @owned $X):
11399 br body2(%borrow_2 : $X, %value_2 : $X)
114100
115101body2(%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-
120102 %hold = function_ref @holdX : $@convention(thin) (@guaranteed X) -> ()
121103 apply %hold(%borrow_3) : $@convention(thin) (@guaranteed X) -> ()
122104 end_borrow %borrow_3 : $X
@@ -144,10 +126,6 @@ body1(%value_2 : @owned $X):
144126 br body2(%lifetime_2 : $X, %value_2 : $X)
145127
146128body2(%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-
151129 end_borrow %lifetime_3 : $X
152130 destroy_value %value_3 : $X
153131 br exit
@@ -180,11 +158,6 @@ body:
180158 %get = function_ref @getX : $@convention(thin) () -> (@owned X)
181159 %value_0 = apply %get() : $@convention(thin) () -> (@owned X)
182160 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-
188161 destroy_value %value : $FakeOptional<X>
189162 %some_value_0 = enum $FakeOptional<X>, #FakeOptional.some!enumelt, %value_0 : $X
190163 %some_borrow_0 = begin_borrow %some_value_0 : $FakeOptional<X>
244217 br bb1(%8 : $X, %9 : $X)
245218
246219bb10:
247- // TODO: Remove the copy once it isn't necessary to trigger canonicalization.
248- %bogus = copy_value %4 : $X
249- destroy_value %bogus : $X
250220 %23 = tuple ()
251221 end_borrow %3 : $X
252222 destroy_value %4 : $X
@@ -269,8 +239,6 @@ reborrow_only(%lifetime_3 : @guaranteed $X):
269239 br exit
270240
271241exit:
272- %bogus = copy_value %value_2 : $X
273- destroy_value %bogus : $X
274242 %retval = tuple ()
275243 end_borrow %lifetime_3 : $X
276244 destroy_value %value_2 : $X
@@ -296,8 +264,6 @@ reborrow_only_2(%lifetime_4 : @guaranteed $X):
296264 br exit
297265
298266exit:
299- %bogus = copy_value %value_2 : $X
300- destroy_value %bogus : $X
301267 %retval = tuple ()
302268 end_borrow %lifetime_4 : $X
303269 destroy_value %value_2 : $X
0 commit comments