/// An error that occurred at some stage of parsing. #[allow(variant_size_differences)] #[non_exhaustive] #[derive(Debug, Clone, Copy, PartialEq, Eq)] pubenum Parse { #[allow(missing_docs)]
TryFromParsed(TryFromParsed), #[allow(missing_docs)]
ParseFromDescription(ParseFromDescription), /// The input should have ended, but there were characters remaining. #[non_exhaustive] #[deprecated(
since = "0.3.28",
note = "no longer output. moved to the `ParseFromDescription` variant"
)]
UnexpectedTrailingCharacters,
}
impl fmt::Display for Parse { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { matchself { Self::TryFromParsed(err) => err.fmt(f), Self::ParseFromDescription(err) => err.fmt(f), #[allow(deprecated)] Self::UnexpectedTrailingCharacters => bug!("variant should not be used"),
}
}
}
#[cfg(feature = "std")] impl std::error::Error for Parse { fn source(&self) -> Option<&(dyn std::error::Error + 'static)> { matchself { Self::TryFromParsed(err) => Some(err), Self::ParseFromDescription(err) => Some(err), #[allow(deprecated)] Self::UnexpectedTrailingCharacters => bug!("variant should not be used"),
}
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.