diff options
| author | Marijn Schouten <mhkbst@gmail.com> | 2025-07-04 11:27:13 +0000 |
|---|---|---|
| committer | Marijn Schouten <mhkbst@gmail.com> | 2025-07-04 11:35:00 +0000 |
| commit | b315e9a2ceb341e07983f028347beafaa60cda0a (patch) | |
| tree | 4edd7668c9fbc993d6f281329a8cacc1eba17278 /library/core/src/ops | |
| parent | c96a69059ecc618b519da385a6ccd03155aa0237 (diff) | |
clippy fix: rely on autoderef
Diffstat (limited to 'library/core/src/ops')
| -rw-r--r-- | library/core/src/ops/deref.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/library/core/src/ops/deref.rs b/library/core/src/ops/deref.rs index 9d9d18095bc..c2dede9fa08 100644 --- a/library/core/src/ops/deref.rs +++ b/library/core/src/ops/deref.rs @@ -158,7 +158,7 @@ impl<T: ?Sized> const Deref for &T { #[rustc_diagnostic_item = "noop_method_deref"] fn deref(&self) -> &T { - *self + self } } @@ -171,7 +171,7 @@ impl<T: ?Sized> const Deref for &mut T { type Target = T; fn deref(&self) -> &T { - *self + self } } @@ -280,7 +280,7 @@ pub trait DerefMut: ~const Deref + PointeeSized { #[rustc_const_unstable(feature = "const_deref", issue = "88955")] impl<T: ?Sized> const DerefMut for &mut T { fn deref_mut(&mut self) -> &mut T { - *self + self } } |
