kitab

Unnamed repository; edit this file 'description' to name the repository.
Info | Log | Files | Refs | LICENSE

error.rs (258B)


      1 /// Used for any parsing error for any supported format.
      2 #[derive(Debug)]
      3 pub struct ParseError {
      4     pub detail: String,
      5 }
      6 
      7 impl ParseError {
      8     pub fn new(s: &str) -> ParseError {
      9         ParseError{
     10             detail: String::from(s),
     11         }
     12     }
     13 }