rustfmt_nightly::rewrite

Trait RewriteErrorExt

source
pub(crate) trait RewriteErrorExt<T> {
    // Required methods
    fn max_width_error(
        self,
        width: usize,
        span: Span,
    ) -> Result<T, RewriteError>;
    fn macro_error(
        self,
        kind: MacroErrorKind,
        span: Span,
    ) -> Result<T, RewriteError>;
    fn unknown_error(self) -> Result<T, RewriteError>;
}
Expand description

Extension trait used to conveniently convert to RewriteError

Required Methods§

Implementations on Foreign Types§

source§

impl<T> RewriteErrorExt<T> for Option<T>

Implementors§