Make duplicate lang items fatal
Prevents terminal spam.
This commit is contained in:
parent
88189a71e4
commit
ad1e6298ed
3 changed files with 6 additions and 19 deletions
|
@ -149,7 +149,9 @@ impl<'ast, 'tcx> LanguageItemCollector<'ast, 'tcx> {
|
|||
}
|
||||
};
|
||||
|
||||
self.tcx.dcx().emit_err(DuplicateLangItem {
|
||||
// When there's a duplicate lang item, something went very wrong and there's no value in recovering or doing anything.
|
||||
// Give the user the one message to let them debug the mess they created and then wish them farewell.
|
||||
self.tcx.dcx().emit_fatal(DuplicateLangItem {
|
||||
local_span: item_span,
|
||||
lang_item_name,
|
||||
crate_name,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue