cargo thiserror 1.0.21

latest releases: 1.0.59, 1.0.58, 1.0.57...
3 years ago
  • Support capturing backtraces inside of Arc from a From impl, which makes it possible for errors having backtraces to be clonable (#102)

    use std::backtrace::Backtrace;
    use std::sync::Arc;
    use thiserror::Error;
    
    #[derive(Error, Debug, Clone)]
    #[error("...")]
    pub struct ClonableErrorWithBacktrace {
        #[from]
        source: Inner,
        #[backtrace]
        backtrace: Arc<Backtrace>,
    }

Don't miss a new thiserror release

NewReleases is sending notifications on new releases.