rustc_errors: let DiagnosticBuilder::emit return a "guarantee of emission".
This commit is contained in:
@@ -40,7 +40,7 @@ use rustc_ast_pretty::pprust;
|
||||
use rustc_data_structures::fx::{FxHashMap, FxHashSet, FxIndexMap};
|
||||
use rustc_data_structures::intern::Interned;
|
||||
use rustc_data_structures::sync::Lrc;
|
||||
use rustc_errors::{struct_span_err, Applicability, Diagnostic, DiagnosticBuilder};
|
||||
use rustc_errors::{struct_span_err, Applicability, Diagnostic, DiagnosticBuilder, ErrorReported};
|
||||
use rustc_expand::base::{DeriveResolutions, SyntaxExtension, SyntaxExtensionKind};
|
||||
use rustc_hir::def::Namespace::*;
|
||||
use rustc_hir::def::{self, CtorOf, DefKind, NonMacroAttrKind, PartialRes};
|
||||
@@ -713,7 +713,7 @@ struct PrivacyError<'a> {
|
||||
}
|
||||
|
||||
struct UseError<'a> {
|
||||
err: DiagnosticBuilder<'a>,
|
||||
err: DiagnosticBuilder<'a, ErrorReported>,
|
||||
/// Candidates which user could `use` to access the missing type.
|
||||
candidates: Vec<ImportSuggestion>,
|
||||
/// The `DefId` of the module to place the use-statements in.
|
||||
|
||||
Reference in New Issue
Block a user