about summary refs log tree commit diff
path: root/clippy_lints/src
diff options
context:
space:
mode:
authorLeón Orell Valerian Liehr <me@fmease.dev>2024-02-11 09:22:52 +0100
committerLeón Orell Valerian Liehr <me@fmease.dev>2024-03-22 06:31:51 +0100
commitb7026f87f52f75ebcb7c0de0c1bf56b714d4b73f (patch)
tree2bbdcf4ec147ffb3fb2395e45183721189b77f7b /clippy_lints/src
parent75390b9f7f2e25f0c3f831a63035bab7cfd98685 (diff)
Update (doc) comments
Several (doc) comments were super outdated or didn't provide enough context.

Some doc comments shoved everything in a single paragraph without respecting
the fact that the first paragraph should be a single sentence because rustdoc
treats these as item descriptions / synopses on module pages.
Diffstat (limited to 'clippy_lints/src')
-rw-r--r--clippy_lints/src/types/redundant_allocation.rs2
-rw-r--r--clippy_lints/src/use_self.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/clippy_lints/src/types/redundant_allocation.rs b/clippy_lints/src/types/redundant_allocation.rs
index 9729c971672..37437cbfbec 100644
--- a/clippy_lints/src/types/redundant_allocation.rs
+++ b/clippy_lints/src/types/redundant_allocation.rs
@@ -56,7 +56,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, hir_ty: &hir::Ty<'tcx>, qpath:
     };
     let inner_span = match qpath_generic_tys(inner_qpath).next() {
         Some(hir_ty) => {
-            // Reallocation of a fat pointer causes it to become thin. `hir_ty_to_ty` is safe to use
+            // Reallocation of a fat pointer causes it to become thin. `lower_ty` is safe to use
             // here because `mod.rs` guarantees this lint is only run on types outside of bodies and
             // is not run on locals.
             let ty = lower_ty(cx.tcx, hir_ty);
diff --git a/clippy_lints/src/use_self.rs b/clippy_lints/src/use_self.rs
index dfa816963bc..a6b411d6c0f 100644
--- a/clippy_lints/src/use_self.rs
+++ b/clippy_lints/src/use_self.rs
@@ -193,7 +193,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf {
     }
 
     fn check_body(&mut self, _: &LateContext<'_>, _: &hir::Body<'_>) {
-        // `hir_ty_to_ty` cannot be called in `Body`s or it will panic (sometimes). But in bodies
+        // `lower_ty` cannot be called in `Body`s or it will panic (sometimes). But in bodies
         // we can use `cx.typeck_results.node_type(..)` to get the `ty::Ty` from a `hir::Ty`.
         // However the `node_type()` method can *only* be called in bodies.
         if let Some(&mut StackItem::Check { ref mut in_body, .. }) = self.stack.last_mut() {