pub enum RequireParseError {
Empty,
Tag(CapabilityTagError),
NumericParse {
key: String,
value: String,
},
InvalidKey {
key: String,
},
InvalidAxis {
axis: String,
},
}Expand description
Errors raised by the require! family of macros at parse time.
All are programmer errors — the macros panic with these
messages so misuse fails loudly at first run.
Variants§
Empty
Empty input passed to a require*! macro.
Tag(CapabilityTagError)
Wrapped CapabilityTagError from tag parsing
(e.g. user attempted to emit a reserved-prefix tag).
NumericParse
Numeric comparison’s right-hand side did not parse to
f64. Carries the original lhs / rhs spelling for
diagnostics.
Fields
InvalidKey
Tag key (<axis>.<key>) couldn’t be parsed (missing dot or
unknown axis prefix).
InvalidAxis
Unknown axis literal passed to require_axis!.
Trait Implementations§
Source§impl Debug for RequireParseError
impl Debug for RequireParseError
Source§impl Display for RequireParseError
impl Display for RequireParseError
Source§impl Error for RequireParseError
impl Error for RequireParseError
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()
Source§impl From<CapabilityTagError> for RequireParseError
impl From<CapabilityTagError> for RequireParseError
Source§fn from(source: CapabilityTagError) -> Self
fn from(source: CapabilityTagError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for RequireParseError
impl RefUnwindSafe for RequireParseError
impl Send for RequireParseError
impl Sync for RequireParseError
impl Unpin for RequireParseError
impl UnsafeUnpin for RequireParseError
impl UnwindSafe for RequireParseError
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