You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Auto merge of #148376 - jhpratt:rollup-tfn2bbb, r=jhpratt
Rollup of 12 pull requests
Successful merges:
- #147137 (Mention crate being analyzed in query description)
- #147642 (Miscellaneous const-generics-related fixes)
- #147806 (Ignore test-dashboard related files)
- #147947 (Implement `strip_circumfix` lib feature)
- #148194 (compiletest: Remove `cleanup_debug_info_options`)
- #148199 (compiletest: Don't modify `testpaths` when creating aux contexts)
- #148247 (Remove two special cases from reachable_non_generics)
- #148348 (dangling ptr lint cleanup)
- #148357 (temporary-lifetime-extension.rs test works in all editions)
- #148362 (docs: makes a note about possible building `rustc 1.91.0 + host tools` for win7)
- #148367 (Use --print host-tuple to get the host)
- #148374 (miri subtree update)
r? `@ghost`
`@rustbot` modify labels: rollup
Copy file name to clipboardExpand all lines: compiler/rustc_lint/messages.ftl
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -193,11 +193,11 @@ lint_confusable_identifier_pair = found both `{$existing_sym}` and `{$sym}` as i
193
193
.current_use = this identifier can be confused with `{$existing_sym}`
194
194
.other_use = other identifier used here
195
195
196
-
lint_dangling_pointers_from_locals = a dangling pointer will be produced because the local variable `{$local_var_name}` will be dropped
197
-
.ret_ty = return type of the {$fn_kind}is `{$ret_ty}`
198
-
.local_var = `{$local_var_name}` is part the {$fn_kind} and will be dropped at the end of the {$fn_kind}
196
+
lint_dangling_pointers_from_locals = {$fn_kind} returns a dangling pointer to dropped local variable `{$local_var_name}`
197
+
.ret_ty = return type is `{$ret_ty}`
198
+
.local_var = local variable `{$local_var_name}` is dropped at the end of the {$fn_kind}
199
199
.created_at = dangling pointer created here
200
-
.note = pointers do not have a lifetime; after returning, the `{$local_var_ty}` will be deallocated at the end of the {$fn_kind} because nothing is referencing it as far as the type system is concerned
200
+
.note = a dangling pointer is safe, but dereferencing one is undefined behavior
201
201
202
202
lint_dangling_pointers_from_temporaries = a dangling pointer will be produced because the temporary `{$ty}` will be dropped
203
203
.label_ptr = this pointer will immediately be invalid
0 commit comments