#[non_exhaustive]pub enum CanonicalizeError {
Parse(String),
InputTooLong {
limit: usize,
},
TooDeep {
limit: usize,
},
NotRoundTrippable(String),
Unsupported(String),
}Expand description
Why a predicate could not be turned into canonical text.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Parse(String)
The SQL did not parse. The message comes from the parser.
InputTooLong
The input was longer than the crate will accept. Shortening it may succeed.
TooDeep
The expression nested deeper than the crate will walk. Simplifying it may succeed.
NotRoundTrippable(String)
The predicate has no canonical spelling the parser can read back unchanged, so hashing it would risk giving two different predicates one key.
Unsupported(String)
Syntax this crate does not canonicalize.
Trait Implementations§
Source§impl Clone for CanonicalizeError
impl Clone for CanonicalizeError
Source§impl Debug for CanonicalizeError
impl Debug for CanonicalizeError
Source§impl Display for CanonicalizeError
impl Display for CanonicalizeError
impl Eq for CanonicalizeError
Source§impl Error for CanonicalizeError
impl Error for CanonicalizeError
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()
Source§impl PartialEq for CanonicalizeError
impl PartialEq for CanonicalizeError
impl StructuralPartialEq for CanonicalizeError
Auto Trait Implementations§
impl Freeze for CanonicalizeError
impl RefUnwindSafe for CanonicalizeError
impl Send for CanonicalizeError
impl Sync for CanonicalizeError
impl Unpin for CanonicalizeError
impl UnsafeUnpin for CanonicalizeError
impl UnwindSafe for CanonicalizeError
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