Skip to content

Commit b42244c

Browse files
committed
Auto merge of #101560 - Dylan-DPC:rollup-8m8yr89, r=Dylan-DPC
Rollup of 6 pull requests Successful merges: - #101153 (Migrate another part of rustc_infer to session diagnostic) - #101399 (Shrink span for bindings with subpatterns.) - #101422 (Hermit: Add File::set_time stub) - #101455 (Avoid UB in the Windows filesystem code in... bootstrap?) - #101498 (rustc: Parameterize `ty::Visibility` over used ID) - #101549 (Use HashStable_Generic in rustc_type_ir) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2 parents 44adfcc + 7f46d73 commit b42244c

File tree

70 files changed

+1200
-807
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+1200
-807
lines changed

Cargo.lock

+1
Original file line numberDiff line numberDiff line change
@@ -3958,6 +3958,7 @@ dependencies = [
39583958
"rustc_session",
39593959
"rustc_span",
39603960
"rustc_target",
3961+
"rustc_type_ir",
39613962
"smallvec",
39623963
"thin-vec",
39633964
"tracing",

compiler/rustc_error_messages/locales/en-US/infer.ftl

+60-2
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,67 @@ infer_relate_object_bound = ...so that it can be closed over into an object
104104
infer_data_borrowed = ...so that the type `{$name}` is not borrowed for too long
105105
infer_reference_outlives_referent = ...so that the reference type `{$name}` does not outlive the data it points at
106106
infer_relate_param_bound = ...so that the type `{$name}` will meet its required lifetime bounds{$continues ->
107-
[true] ...
108-
*[false] {""}
107+
[true] ...
108+
*[false] {""}
109109
}
110110
infer_relate_param_bound_2 = ...that is required by this bound
111111
infer_relate_region_param_bound = ...so that the declared lifetime parameter bounds are satisfied
112112
infer_compare_impl_item_obligation = ...so that the definition in impl matches the definition from the trait
113+
114+
infer_nothing = {""}
115+
116+
infer_lifetime_mismatch = lifetime mismatch
117+
118+
infer_declared_different = this parameter and the return type are declared with different lifetimes...
119+
infer_data_returned = ...but data{$label_var1_exists ->
120+
[true] {" "}from `{$label_var1}`
121+
*[false] {""}
122+
} is returned here
123+
124+
infer_data_lifetime_flow = ...but data with one lifetime flows into the other here
125+
infer_declared_multiple = this type is declared with multiple lifetimes...
126+
infer_types_declared_different = these two types are declared with different lifetimes...
127+
infer_data_flows = ...but data{$label_var1_exists ->
128+
[true] -> {" "}from `{$label_var1}`
129+
*[false] -> {""}
130+
} flows{$label_var2_exists ->
131+
[true] -> {" "}into `{$label_var2}`
132+
*[false] -> {""}
133+
} here
134+
135+
infer_lifetime_param_suggestion = consider introducing a named lifetime parameter{$is_impl ->
136+
[true] {" "}and update trait if needed
137+
*[false] {""}
138+
}
139+
infer_lifetime_param_suggestion_elided = each elided lifetime in input position becomes a distinct lifetime
140+
141+
infer_region_explanation = {$pref_kind ->
142+
*[should_not_happen] [{$pref_kind}]
143+
[empty] {""}
144+
}{$pref_kind ->
145+
[empty] {""}
146+
*[other] {" "}
147+
}{$desc_kind ->
148+
*[should_not_happen] [{$desc_kind}]
149+
[restatic] the static lifetime
150+
[reempty] the empty lifetime
151+
[reemptyuni] the empty lifetime in universe {$desc_arg}
152+
[revar] lifetime {$desc_arg}
153+
154+
[as_defined] the lifetime `{$desc_arg}` as defined here
155+
[as_defined_anon] the anonymous lifetime as defined here
156+
[defined_here] the anonymous lifetime defined here
157+
[anon_num_here] the anonymous lifetime #{$desc_num_arg} defined here
158+
[defined_here_reg] the lifetime `{$desc_arg}` as defined here
159+
}{$suff_kind ->
160+
*[should_not_happen] [{$suff_kind}]
161+
[empty]{""}
162+
[continues] ...
163+
}
164+
165+
infer_mismatched_static_lifetime = incompatible lifetime on type
166+
infer_msl_impl_note = ...does not necessarily outlive the static lifetime introduced by the compatible `impl`
167+
infer_msl_introduces_static = introduces a `'static` lifetime requirement
168+
infer_msl_unmet_req = because this has an unmet lifetime requirement
169+
infer_msl_trait_note = this has an implicit `'static` lifetime requirement
170+
infer_msl_trait_sugg = consider relaxing the implicit `'static` requirement

compiler/rustc_infer/src/errors.rs

-254
This file was deleted.

0 commit comments

Comments
 (0)