use crate::model::macho_file::MachoFile;
pub trait MachoExt<'data>: Sized {
type Error;
fn parse<'mf>(macho: &'mf MachoFile<'data>) -> Result<Self, Self::Error>
where
'data: 'mf;
}
impl<'data> MachoFile<'data> {
pub fn ext<E: MachoExt<'data>>(&self) -> Result<E, E::Error> {
E::parse(self)
}
}