From 630a934df076af7054405ccd07985bbc58d38e5a Mon Sep 17 00:00:00 2001 From: mwojcik Date: Tue, 27 Jul 2021 10:27:43 +0200 Subject: [PATCH] removed mentions of fail, updated alloc --- src/libio/Cargo.toml | 5 +++-- src/libio/lib.rs | 13 +++++-------- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/src/libio/Cargo.toml b/src/libio/Cargo.toml index 6aacf0c4..c02f08ab 100644 --- a/src/libio/Cargo.toml +++ b/src/libio/Cargo.toml @@ -8,9 +8,10 @@ name = "io" path = "lib.rs" [dependencies] -failure = { version = "0.1", default-features = false } -failure_derive = { version = "0.1", default-features = false } +core_io = { version = "0.1", features = ["collections"] } byteorder = { version = "1.0", default-features = false, optional = true } +libsupport_zynq = { default-features = false, features = ["alloc_core"], git = "https://git.m-labs.hk/M-Labs/zynq-rs.git" } + [features] alloc = [] diff --git a/src/libio/lib.rs b/src/libio/lib.rs index b10c4134..b3e8e6b9 100644 --- a/src/libio/lib.rs +++ b/src/libio/lib.rs @@ -2,12 +2,12 @@ #![feature(never_type)] #![cfg_attr(feature = "alloc", feature(alloc))] -extern crate failure; -#[macro_use] -extern crate failure_derive; +extern crate alloc; +extern crate core_io; + #[cfg(feature = "alloc")] #[macro_use] -extern crate alloc; +use alloc; #[cfg(feature = "byteorder")] extern crate byteorder; @@ -21,12 +21,9 @@ pub use proto::{ProtoRead, ProtoWrite}; #[cfg(all(feature = "byteorder", feature = "alloc"))] pub use proto::ReadStringError; -#[derive(Fail, Debug, Clone, PartialEq)] pub enum Error { - #[fail(display = "unexpected end of stream")] UnexpectedEnd, - #[fail(display = "{}", _0)] - Other(#[cause] T) + Other(T) } impl From for Error {