Auto merge of #122113 - matthiaskrgr:rollup-5d1jnwi, r=matthiaskrgr
Rollup of 9 pull requests Successful merges: - #121958 (Fix redundant import errors for preload extern crate) - #121976 (Add an option to have an external download/bootstrap cache) - #122022 (loongarch: add frecipe and relax target feature) - #122026 (Do not try to format removed files) - #122027 (Uplift some feeding out of `associated_type_for_impl_trait_in_impl` and into queries) - #122063 (Make the lowering of `thir::ExprKind::If` easier to follow) - #122074 (Add missing PartialOrd trait implementation doc for array) - #122082 (remove outdated fixme comment) - #122091 (Note why we're using a new thread in `test_get_os_named_thread`) r? `@ghost` `@rustbot` modify labels: rollup
This commit is contained in:
commit
aa029ce4d8
31 changed files with 402 additions and 180 deletions
|
@ -143,7 +143,11 @@ pub(super) fn builtin(sess: &Session, diagnostic: BuiltinLintDiag, diag: &mut Di
|
|||
BuiltinLintDiag::RedundantImport(spans, ident) => {
|
||||
for (span, is_imported) in spans {
|
||||
let introduced = if is_imported { "imported" } else { "defined" };
|
||||
diag.span_label(span, format!("the item `{ident}` is already {introduced} here"));
|
||||
let span_msg = if span.is_dummy() { "by prelude" } else { "here" };
|
||||
diag.span_label(
|
||||
span,
|
||||
format!("the item `{ident}` is already {introduced} {span_msg}"),
|
||||
);
|
||||
}
|
||||
}
|
||||
BuiltinLintDiag::DeprecatedMacro(suggestion, span) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue