pub struct Warnings(/* private fields */);Expand description
Set of Warnings.
Implementations§
Source§impl Warnings
impl Warnings
Sourcepub fn iter(&self) -> impl ExactSizeIterator<Item = &Warning> + '_
pub fn iter(&self) -> impl ExactSizeIterator<Item = &Warning> + '_
Iterates over the contained warnings in no particular order.
Sourcepub fn into_result(self) -> Result<(), Self>
pub fn into_result(self) -> Result<(), Self>
Converts these warnings into a Result. This is useful to treat warnings as errors.
§Errors
Returns Err(_) if there’s at least one warning.
Trait Implementations§
Source§impl Error for Warnings
Available on crate feature std only.
impl Error for Warnings
Available on crate feature
std only.1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for Warnings
impl RefUnwindSafe for Warnings
impl Send for Warnings
impl Sync for Warnings
impl Unpin for Warnings
impl UnwindSafe for Warnings
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