Commit 5e7af6b
authored
Rollup merge of rust-lang#142700 - theemathas:remove-weak-comment, r=ibraheemdev
Remove incorrect comments in `Weak`
It is currently possible to create a dangling `Weak` to a DST by calling `Weak::new()` for a sized type, then doing an unsized coercion. Therefore, the comments are wrong.
These comments were added in <rust-lang#73845>. As far as I can tell, the guarantee in the comment was only previously used in the `as_ptr` method. However, the current implementation of `as_ptr` no longer relies on this guarantee.2 files changed
+0
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3004 | 3004 | | |
3005 | 3005 | | |
3006 | 3006 | | |
3007 | | - | |
3008 | 3007 | | |
3009 | 3008 | | |
3010 | 3009 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
342 | 342 | | |
343 | 343 | | |
344 | 344 | | |
345 | | - | |
346 | 345 | | |
347 | 346 | | |
348 | 347 | | |
| |||
0 commit comments