pub enum RenderError {
MalformedTree(String),
}Expand description
Error returned by the descriptor_to_template renderer.
The renderer’s Err arms are fail-closed structural guards that never
fire on a decoder-produced Descriptor (a decoded AST is always
well-formed). They exist so a foreign/test-fabricated tree with an
impossible tag/body pairing produces a typed error instead of malformed
output. Kept a separate type from crate::Error (the wire/decode
taxonomy) because a text-render failure is not a wire error.
Variants§
MalformedTree(String)
A tree node had a structurally-malformed tag/body pairing the renderer
cannot serialize (e.g. a Tag::Tr without a Body::Tr).
Trait Implementations§
Source§impl Clone for RenderError
impl Clone for RenderError
Source§fn clone(&self) -> RenderError
fn clone(&self) -> RenderError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RenderError
impl Debug for RenderError
Source§impl Display for RenderError
impl Display for RenderError
impl Eq for RenderError
Source§impl Error for RenderError
impl Error for RenderError
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 RenderError
impl PartialEq for RenderError
Source§fn eq(&self, other: &RenderError) -> bool
fn eq(&self, other: &RenderError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for RenderError
Auto Trait Implementations§
impl Freeze for RenderError
impl RefUnwindSafe for RenderError
impl Send for RenderError
impl Sync for RenderError
impl Unpin for RenderError
impl UnsafeUnpin for RenderError
impl UnwindSafe for RenderError
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