Struct geo_aid::cli::DiagnosticData
source · pub struct DiagnosticData {
pub message: String,
pub spans: Vec<Span>,
pub annotations: Vec<Annotation>,
pub notes: Vec<(AnnotationKind, String)>,
pub fixes: Vec<Fix>,
}
Fields§
§message: String
§spans: Vec<Span>
§annotations: Vec<Annotation>
§notes: Vec<(AnnotationKind, String)>
§fixes: Vec<Fix>
Implementations§
source§impl DiagnosticData
impl DiagnosticData
pub fn new<S: ToString + ?Sized>(message: &S) -> Self
pub fn add_note(self, kind: AnnotationKind, message: String) -> Self
pub fn add_span(self, sp: Span) -> Self
pub fn add_annotation<S: ToString + ?Sized>( self, at: Span, kind: AnnotationKind, message: &S, ) -> Self
pub fn add_annotation_opt_msg<S: ToString + ?Sized>( self, at: Span, kind: AnnotationKind, message: Option<&S>, ) -> Self
pub fn add_annotation_opt_span<S: ToString + ?Sized>( self, at: Option<Span>, kind: AnnotationKind, message: &S, ) -> Self
pub fn add_fix(self, fix: Fix) -> Self
Auto Trait Implementations§
impl Freeze for DiagnosticData
impl RefUnwindSafe for DiagnosticData
impl Send for DiagnosticData
impl Sync for DiagnosticData
impl Unpin for DiagnosticData
impl UnwindSafe for DiagnosticData
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Convert for T
impl<T> Convert for T
source§fn convert<U>(self, context: &CompileContext) -> Expr<U>where
U: ConvertFrom<T>,
fn convert<U>(self, context: &CompileContext) -> Expr<U>where
U: ConvertFrom<T>,
Errors Read more
source§fn can_convert<U>(&self) -> boolwhere
U: ConvertFrom<T>,
fn can_convert<U>(&self) -> boolwhere
U: ConvertFrom<T>,
Errors Read more