pub enum ErrorKind {
MissingWrapper {
expected: &'static str,
found: String,
suggestion: String,
},
EmptyGenericArgs {
wrapper: &'static str,
},
UnsupportedType {
name: String,
reason: &'static str,
suggestion: &'static str,
},
InvalidAttrValue {
attr: String,
expected: &'static str,
found: String,
},
MissingRequiredAttr {
attr: &'static str,
context: &'static str,
},
ConflictingAttrs {
first: String,
second: String,
suggestion: String,
},
MissingReturnType {
fn_name: String,
},
InvalidHandlerSig {
fn_name: String,
reason: &'static str,
},
UnknownKey {
key: String,
valid_keys: &'static [&'static str],
},
SynError(Error),
}Variants§
MissingWrapper
A type was found where a specific wrapper was expected.
EmptyGenericArgs
A wrapper type has no generic arguments (e.g. bare Json instead of Json<T>).
UnsupportedType
A type that orpc does not know how to handle appears in a handler signature.
InvalidAttrValue
An attribute key has a value of the wrong kind (e.g. non-string literal).
MissingRequiredAttr
A required attribute key is absent.
ConflictingAttrs
Two attribute keys that cannot coexist were both provided.
MissingReturnType
A handler function has no return type annotation.
InvalidHandlerSig
A handler function’s signature does not match the expected shape.
UnknownKey
An unrecognised key was provided in a macro attribute.
SynError(Error)
A syn parse error forwarded directly.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ErrorKind
impl RefUnwindSafe for ErrorKind
impl Send for ErrorKind
impl Sync for ErrorKind
impl Unpin for ErrorKind
impl UnsafeUnpin for ErrorKind
impl UnwindSafe for ErrorKind
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