1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#[cfg(feature = "http_client")]
use attohttpc as http_client;
pub type IoResult<T> = Result<T, IoError>;
#[derive(Debug, thiserror::Error)]
#[non_exhaustive]
pub enum IoError {
#[error("Unable to create or access RustReleases cache")]
DlCache,
#[cfg(feature = "http_client")]
#[error("{0}")]
HttpClient(#[from] http_client::Error),
#[error("{0}")]
Io(#[from] std::io::Error),
#[error("Release channel '{0}' was not found")]
NoSuchChannel(String),
#[error("{0}")]
SystemTime(#[from] std::time::SystemTimeError),
}