summaryrefslogtreecommitdiffstats
path: root/src/parser/mod.rs
diff options
context:
space:
mode:
authorMatthias Beyer <mail@beyermatthias.de>2020-03-05 19:48:58 +0100
committerMatthias Beyer <mail@beyermatthias.de>2020-03-05 19:48:58 +0100
commit07f108e1d25da387735ce2ddca04a768a2739d9f (patch)
tree3b19df5d2c22d8954b446f22f014e50dea33876a /src/parser/mod.rs
parent0b9130fd4e0a85e9603f2eee4678a6326aaf87c4 (diff)
Replace failure with thiserror
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Diffstat (limited to 'src/parser/mod.rs')
-rw-r--r--src/parser/mod.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/parser/mod.rs b/src/parser/mod.rs
index c6483b4..88d0020 100644
--- a/src/parser/mod.rs
+++ b/src/parser/mod.rs
@@ -49,8 +49,8 @@ use nom::IResult;
mod timetype;
mod iterator;
-use failure::Fallible as Result;
-use error::ErrorKind as KEK;
+use error::Result;
+use error::Error;
use iter::Iter;
use timetype::IntoTimeType;
use parser::timetype::timetype;
@@ -71,8 +71,8 @@ pub fn parse(s: &str) -> Result<Parsed> {
IResult::Done(_, Ok(o)) => Ok(o),
IResult::Done(_, Err(e)) => Err(e),
IResult::Error(e) => Err(e).map_err(From::from),
- IResult::Incomplete(Needed::Unknown) => Err(KEK::UnknownParserError.into()),
- IResult::Incomplete(Needed::Size(_)) => Err(KEK::UnknownParserError.into()),
+ IResult::Incomplete(Needed::Unknown) => Err(Error::UnknownParserError),
+ IResult::Incomplete(Needed::Size(_)) => Err(Error::UnknownParserError),
}
}