1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
use thiserror::Error; /// Perf.data reader error #[derive(Error, Debug)] #[non_exhaustive] pub enum ReaderError { /// The `perf.data` file is invalid in format #[error("Invalid perf.data")] InvalidPerfData, /// Unexpected EOF #[error("Unexpected EOF")] UnexpectedEOF, } pub(crate) type ReaderResult<T> = core::result::Result<T, ReaderError>;