|
|
@ -66,16 +66,11 @@ use syn::parse_macro_input; |
|
|
|
///
|
|
|
|
/// /// For all types used in the `Error` position of a `Result` in the module
|
|
|
|
/// /// traits, you must implement `GuestErrorType` which tells wiggle-generated
|
|
|
|
/// /// code how to determine if a method call has been successful, as well as
|
|
|
|
/// /// how to translate a wiggle runtime error into an ABI-level error.
|
|
|
|
/// impl<'a> GuestErrorType<'a> for types::Errno {
|
|
|
|
/// type Context = YourCtxType;
|
|
|
|
/// /// code what value to return when the method returns Ok(...).
|
|
|
|
/// impl GuestErrorType for types::Errno {
|
|
|
|
/// fn success() -> Self {
|
|
|
|
/// unimplemented!()
|
|
|
|
/// }
|
|
|
|
/// fn from_error(_e: wiggle::GuestError, _c: &Self::Context) -> Self {
|
|
|
|
/// unimplemented!()
|
|
|
|
/// }
|
|
|
|
/// }
|
|
|
|
///
|
|
|
|
/// # fn main() { println!("this fools doc tests into compiling the above outside a function body")
|
|
|
|