mirror of
https://github.com/icewind1991/mhz19-rs
synced 2026-06-03 17:44:09 +02:00
make it build again
This commit is contained in:
parent
13edafcf0a
commit
9ee5041003
2 changed files with 1 additions and 12 deletions
|
|
@ -19,4 +19,4 @@ path = "src/bin.rs"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
"serial" = "0.4"
|
"serial" = "0.4"
|
||||||
err-derive = "0.1"
|
err-derive = "0.3"
|
||||||
|
|
|
||||||
11
src/lib.rs
11
src/lib.rs
|
|
@ -14,17 +14,6 @@ pub enum Error {
|
||||||
CRC,
|
CRC,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl From<serial::Error> for Error {
|
|
||||||
fn from(err: serial::Error) -> Self {
|
|
||||||
Error::Serial(err)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
impl From<std::io::Error> for Error {
|
|
||||||
fn from(err: std::io::Error) -> Self {
|
|
||||||
Error::IO(err)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
pub type Result<T> = std::result::Result<T, Error>;
|
pub type Result<T> = std::result::Result<T, Error>;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue