aya: bpf: remove lifetime param from previous signature

pull/1/head
Alessandro Decina 4 years ago
parent ed53f7470b
commit dcb5121985

@ -194,15 +194,15 @@ impl Bpf {
ret ret
} }
pub fn program<'a, 'slf: 'a, T: TryFrom<&'a Program>>( pub fn program<'a, T: TryFrom<&'a Program>>(
&'slf self, &'a self,
name: &str, name: &str,
) -> Result<Option<T>, <T as TryFrom<&'a Program>>::Error> { ) -> Result<Option<T>, <T as TryFrom<&'a Program>>::Error> {
self.programs.get(name).map(|p| T::try_from(p)).transpose() self.programs.get(name).map(|p| T::try_from(p)).transpose()
} }
pub fn program_mut<'a, 'slf: 'a, T: TryFrom<&'a mut Program>>( pub fn program_mut<'a, T: TryFrom<&'a mut Program>>(
&'slf mut self, &'a mut self,
name: &str, name: &str,
) -> Result<Option<T>, <T as TryFrom<&'a mut Program>>::Error> { ) -> Result<Option<T>, <T as TryFrom<&'a mut Program>>::Error> {
self.programs self.programs

Loading…
Cancel
Save