SpanLabel in rustc_errors - Rust (original) (raw)
pub struct SpanLabel {
pub span: Span,
pub is_primary: bool,
pub label: Option<DiagMessage>,
}
Expand description
A span together with some additional data.
The span we are going to include in the final snippet.
Is this a primary span? This is the “locus” of the message, and is indicated with a ^^^^
underline, versus ----
.
What label should we attach to this span (if any)?
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 64 bytes