Make early lints translatable
This commit is contained in:
parent
b7abf014ec
commit
8004e6a379
27 changed files with 1176 additions and 550 deletions
|
@ -1364,17 +1364,15 @@ fn pretty_printing_compatibility_hack(item: &Item, sess: &Session) -> bool {
|
|||
};
|
||||
|
||||
if crate_matches {
|
||||
// FIXME: make this translatable
|
||||
#[allow(rustc::untranslatable_diagnostic)]
|
||||
sess.psess.buffer_lint_with_diagnostic(
|
||||
PROC_MACRO_BACK_COMPAT,
|
||||
item.ident.span,
|
||||
ast::CRATE_NODE_ID,
|
||||
BuiltinLintDiag::ProcMacroBackCompat(
|
||||
"older versions of the `rental` crate will stop compiling in future versions of Rust; \
|
||||
please update to `rental` v0.5.6, or switch to one of the `rental` alternatives".to_string()
|
||||
)
|
||||
);
|
||||
PROC_MACRO_BACK_COMPAT,
|
||||
item.ident.span,
|
||||
ast::CRATE_NODE_ID,
|
||||
BuiltinLintDiag::ProcMacroBackCompat {
|
||||
crate_name: "rental".to_string(),
|
||||
fixed_version: "0.5.6".to_string(),
|
||||
},
|
||||
);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue