diff options
author | Joe Wilm <joe@jwilm.com> | 2016-12-16 22:13:51 -0800 |
---|---|---|
committer | Joe Wilm <joe@jwilm.com> | 2016-12-16 22:13:51 -0800 |
commit | dc918ae71a5e6c78a77994d7ce106a2253918c54 (patch) | |
tree | 537c7d13443e18ed657398f4eca0bf921ef4ac5e /src/grid.rs | |
parent | 3b995ff87a54239ecacb95d51f65c17504a8d22c (diff) | |
download | alacritty-dc918ae71a5e6c78a77994d7ce106a2253918c54.tar.gz alacritty-dc918ae71a5e6c78a77994d7ce106a2253918c54.zip |
Rustup and clippy
All of the changes in this commit are due to clippy lints.
Diffstat (limited to 'src/grid.rs')
-rw-r--r-- | src/grid.rs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/grid.rs b/src/grid.rs index 1bcc91ce..7192b996 100644 --- a/src/grid.rs +++ b/src/grid.rs @@ -192,14 +192,14 @@ impl<T> Index<index::Line> for Grid<T> { type Output = Row<T>; #[inline] - fn index<'a>(&'a self, index: index::Line) -> &'a Row<T> { + fn index(&self, index: index::Line) -> &Row<T> { &self.raw[index.0] } } impl<T> IndexMut<index::Line> for Grid<T> { #[inline] - fn index_mut<'a>(&'a mut self, index: index::Line) -> &'a mut Row<T> { + fn index_mut(&mut self, index: index::Line) -> &mut Row<T> { &mut self.raw[index.0] } } @@ -208,7 +208,7 @@ impl<'cursor, T> Index<&'cursor Cursor> for Grid<T> { type Output = T; #[inline] - fn index<'a, 'b>(&'a self, cursor: &'b Cursor) -> &'a T { + fn index<'a>(&'a self, cursor: &Cursor) -> &'a T { &self.raw[cursor.line.0][cursor.col] } } @@ -294,14 +294,14 @@ impl<T> Index<index::Column> for Row<T> { type Output = T; #[inline] - fn index<'a>(&'a self, index: index::Column) -> &'a T { + fn index(&self, index: index::Column) -> &T { &self.0[index.0] } } impl<T> IndexMut<index::Column> for Row<T> { #[inline] - fn index_mut<'a>(&'a mut self, index: index::Column) -> &'a mut T { + fn index_mut(&mut self, index: index::Column) -> &mut T { &mut self.0[index.0] } } @@ -312,14 +312,14 @@ macro_rules! row_index_range { type Output = [T]; #[inline] - fn index<'a>(&'a self, index: $range) -> &'a [T] { + fn index(&self, index: $range) -> &[T] { &self.0[index] } } impl<T> IndexMut<$range> for Row<T> { #[inline] - fn index_mut<'a>(&'a mut self, index: $range) -> &'a mut [T] { + fn index_mut(&mut self, index: $range) -> &mut [T] { &mut self.0[index] } } |