Delegate io::Error::cause to inner error

This commit is contained in:
Steven Fackler 2015-05-26 20:39:14 -07:00
parent 1a3cffbddf
commit 4458b5a9d5

View file

@ -215,6 +215,13 @@ fn description(&self) -> &str {
Repr::Custom(ref c) => c.error.description(),
}
}
fn cause(&self) -> Option<&Error> {
match self.repr {
Repr::Os(..) => None,
Repr::Custom(ref c) => c.error.cause(),
}
}
}
fn _assert_error_is_sync_send() {