Guest User

Untitled

a guest
May 27th, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. struct Backtrace;
  2.  
  3. trait Fail {
  4.  
  5. }
  6.  
  7. struct Error {
  8. pub(crate) inner: Box<Inner<Fail>>,
  9. }
  10.  
  11. struct Inner<F: ?Sized + Fail> {
  12. backtrace: Backtrace,
  13. failure: F,
  14. }
  15.  
  16. struct Ha(u32);
  17.  
  18. impl Fail for Ha {
  19.  
  20. }
  21.  
  22. fn main() {
  23. let ha = Ha(12);
  24.  
  25. let er = Error {
  26. inner: Box::new(Inner{backtrace: Backtrace,failure:ha })
  27.  
  28. };
  29. }
Add Comment
Please, Sign In to add comment