rustc_errors: add downgrade_to_delayed_bug
to Diagnostic
itself.
This commit is contained in:
parent
5bd1ec3283
commit
f24ff1815f
10 changed files with 129 additions and 48 deletions
|
@ -66,7 +66,9 @@ fn source_string(file: Lrc<SourceFile>, line: &Line) -> String {
|
|||
/// Maps `Diagnostic::Level` to `snippet::AnnotationType`
|
||||
fn annotation_type_for_level(level: Level) -> AnnotationType {
|
||||
match level {
|
||||
Level::Bug | Level::Fatal | Level::Error { .. } => AnnotationType::Error,
|
||||
Level::Bug | Level::DelayedBug | Level::Fatal | Level::Error { .. } => {
|
||||
AnnotationType::Error
|
||||
}
|
||||
Level::Warning => AnnotationType::Warning,
|
||||
Level::Note => AnnotationType::Note,
|
||||
Level::Help => AnnotationType::Help,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue