Struct rustfix::diagnostics::Diagnostic
source · pub struct Diagnostic {
pub message: String,
pub code: Option<DiagnosticCode>,
pub spans: Vec<DiagnosticSpan>,
pub children: Vec<Diagnostic>,
pub rendered: Option<String>,
/* private fields */
}
Fields
message: String
The primary error message.
code: Option<DiagnosticCode>
spans: Vec<DiagnosticSpan>
children: Vec<Diagnostic>
Associated diagnostic messages.
rendered: Option<String>
The message as rustc would render it. Currently this is only
Some
for “suggestions”, but eventually it will include all
snippets.
Trait Implementations
sourceimpl Debug for Diagnostic
impl Debug for Diagnostic
sourceimpl<'de> Deserialize<'de> for Diagnostic
impl<'de> Deserialize<'de> for Diagnostic
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Diagnostic
impl Send for Diagnostic
impl Sync for Diagnostic
impl Unpin for Diagnostic
impl UnwindSafe for Diagnostic
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more