pub struct SuppressionDiagnostic { /* private fields */ }

Trait Implementations§

source§

impl Clone for SuppressionDiagnostic

source§

fn clone(&self) -> SuppressionDiagnostic

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for SuppressionDiagnostic

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Diagnostic for SuppressionDiagnostic

source§

fn category(&self) -> Option<&'static Category>

The category of a diagnostic uniquely identifying this diagnostic type, such as lint/correctness/noArguments, args/invalid or format/disabled.
source§

fn description(&self, fmt: &mut Formatter<'_>) -> Result

The description is a text-only explanation of the issue this diagnostic is reporting, intended for display contexts that do not support rich markup such as in-editor popovers Read more
source§

fn message(&self, fmt: &mut Formatter<'_>) -> Result<()>

An explanation of the issue this diagnostic is reporting Read more
source§

fn location(&self) -> Location<'_>

A diagnostic can be tied to a specific “location”: this can be a file, memory buffer, command line argument, etc. It may also be tied to a specific text range within the content of that location. Finally, it may also provide the source string for that location (this is required in order to display a code frame advice for the diagnostic).
source§

fn severity(&self) -> Severity

The severity defines whether this diagnostic reports an error, a warning, an information or a hint to the user.
source§

fn advices(&self, visitor: &mut dyn Visit) -> Result<(), Error>

Advices are the main building blocks used compose rich errors. They are implemented using a visitor pattern, where consumers of a diagnostic can visit the object and collect the advices that make it up for the purpose of display or introspection.
source§

fn verbose_advices(&self, visitor: &mut dyn Visit) -> Result<(), Error>

Diagnostics can defines additional advices to be printed if the user requires more detail about the diagnostic.
source§

fn tags(&self) -> DiagnosticTags

Tags convey additional boolean metadata about the nature of a diagnostic: Read more
source§

fn source(&self) -> Option<&dyn Diagnostic>

Similarly to the source method of the std::error::Error trait, this returns another diagnostic that’s the logical “cause” for this issue. For instance, a “request failed” diagnostic may have been cause by a “deserialization error”. This allows low-level error to be wrapped in higher level concepts, while retaining enough information to display and fix the underlying issue.
source§

impl PartialEq for SuppressionDiagnostic

source§

fn eq(&self, other: &SuppressionDiagnostic) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for SuppressionDiagnostic

source§

impl StructuralPartialEq for SuppressionDiagnostic

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<E> DiagnosticExt for E
where E: AsDiagnostic,

source§

fn context<M>(self, message: M) -> Error
where E: 'static, M: Display + 'static, Error: From<ContextDiagnostic<M, E>>,

Returns a new diagnostic with the provided message as a message and description, and self as a source diagnostic. This is useful to create chains of diagnostics, where high level errors wrap lower level causes.
source§

fn with_category(self, category: &'static Category) -> Error
where Error: From<CategoryDiagnostic<E>>,

Returns a new diagnostic using the provided category if self doesn’t already have one.
source§

fn with_file_path(self, path: impl AsResource) -> Error
where Error: From<FilePathDiagnostic<E>>,

Returns a new diagnostic using the provided path if self doesn’t already have one.
source§

fn with_file_span(self, span: impl AsSpan) -> Error
where Error: From<FileSpanDiagnostic<E>>,

Returns a new diagnostic using the provided span instead of the one in self.
source§

fn with_file_source_code(self, source_code: impl AsSourceCode) -> Error
where Error: From<FileSourceCodeDiagnostic<E>>,

Returns a new diagnostic using the provided source_code if self doesn’t already have one.
source§

fn with_tags(self, tags: DiagnosticTags) -> Error
where Error: From<TagsDiagnostic<E>>,

Returns a new diagnostic with additional tags
source§

fn with_severity(self, severity: Severity) -> Error
where Error: From<SeverityDiagnostic<E>>,

Returns a new diagnostic with additional severity
source§

impl<T> DynClone for T
where T: Clone,

source§

fn __clone_box(&self, _: Private) -> *mut ()

source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more