diff --git a/geo-types/src/line_string.rs b/geo-types/src/line_string.rs index a5f6b5d37..1509ed290 100644 --- a/geo-types/src/line_string.rs +++ b/geo-types/src/line_string.rs @@ -171,7 +171,7 @@ impl LineString { /// ); /// assert!(lines.next().is_none()); /// ``` - pub fn lines<'a>(&'a self) -> impl ExactSizeIterator + Iterator> + 'a { + pub fn lines(&'_ self) -> impl ExactSizeIterator + Iterator> + '_ { self.0.windows(2).map(|w| { // slice::windows(N) is guaranteed to yield a slice with exactly N elements unsafe { Line::new(*w.get_unchecked(0), *w.get_unchecked(1)) } @@ -179,7 +179,7 @@ impl LineString { } /// An iterator which yields the coordinates of a `LineString` as `Triangle`s - pub fn triangles<'a>(&'a self) -> impl ExactSizeIterator + Iterator> + 'a { + pub fn triangles(&'_ self) -> impl ExactSizeIterator + Iterator> + '_ { self.0.windows(3).map(|w| { // slice::windows(N) is guaranteed to yield a slice with exactly N elements unsafe {