1
Fork 0

Remove SubDiagnostic::render_span.

It's only ever set to `None`.
This commit is contained in:
Nicholas Nethercote 2023-12-21 10:30:17 +11:00
parent 125337bd68
commit ce0f703554
3 changed files with 3 additions and 10 deletions

View file

@ -424,11 +424,7 @@ impl Diagnostic {
message: translated_message.to_string(),
code: None,
level: diag.level.to_str(),
spans: diag
.render_span
.as_ref()
.map(|sp| DiagnosticSpan::from_multispan(sp, args, je))
.unwrap_or_else(|| DiagnosticSpan::from_multispan(&diag.span, args, je)),
spans: DiagnosticSpan::from_multispan(&diag.span, args, je),
children: vec![],
rendered: None,
}