about summary refs log tree commit diff
diff options
context:
space:
mode:
authorwhodi <whodi@pop-os.localdomain>2022-04-15 14:25:55 -0400
committerManish Goregaokar <manishsmail@gmail.com>2022-04-15 14:18:09 -0700
commit29ef80c78a0f9c58607944e50d3240eee2b7cdc7 (patch)
tree24003199ba08dd7043408fef8799a335c88aecfd
parentc0fce5a8475927a7dc5f56f4efb2468aa87a4da0 (diff)
downloadrust-29ef80c78a0f9c58607944e50d3240eee2b7cdc7.tar.gz
rust-29ef80c78a0f9c58607944e50d3240eee2b7cdc7.zip
adding spell checking
-rw-r--r--.github/ISSUE_TEMPLATE/blank_issue.yml2
-rw-r--r--.github/ISSUE_TEMPLATE/false_negative.yml2
-rw-r--r--.github/ISSUE_TEMPLATE/false_positive.yml2
-rw-r--r--.github/workflows/clippy.yml4
-rw-r--r--clippy_dev/src/setup/git_hook.rs2
-rw-r--r--clippy_dev/src/setup/mod.rs4
-rw-r--r--clippy_lints/src/casts/mod.rs2
-rw-r--r--clippy_lints/src/empty_structs_with_brackets.rs2
-rw-r--r--clippy_lints/src/index_refutable_slice.rs2
-rw-r--r--clippy_lints/src/match_result_ok.rs4
-rw-r--r--clippy_lints/src/matches/match_same_arms.rs4
-rw-r--r--clippy_lints/src/matches/mod.rs4
-rw-r--r--clippy_lints/src/matches/needless_match.rs2
-rw-r--r--clippy_lints/src/methods/mod.rs4
-rw-r--r--clippy_lints/src/missing_inline.rs2
-rw-r--r--clippy_lints/src/needless_bitwise_bool.rs4
-rw-r--r--clippy_lints/src/needless_late_init.rs6
-rw-r--r--clippy_lints/src/octal_escapes.rs2
-rw-r--r--clippy_lints/src/option_if_let_else.rs8
-rw-r--r--clippy_lints/src/suspicious_operation_groupings.rs2
-rw-r--r--clippy_lints/src/transmute/utils.rs2
-rw-r--r--clippy_lints/src/types/mod.rs2
-rw-r--r--clippy_lints/src/unnested_or_patterns.rs2
-rw-r--r--clippy_lints/src/use_self.rs2
-rw-r--r--clippy_lints/src/utils/author.rs2
-rw-r--r--clippy_lints/src/utils/internal_lints.rs4
-rw-r--r--clippy_lints/src/utils/internal_lints/metadata_collector.rs6
-rw-r--r--clippy_utils/src/macros.rs2
-rw-r--r--clippy_utils/src/source.rs2
-rw-r--r--tests/lint_message_convention.rs2
-rw-r--r--tests/ui/auxiliary/proc_macro_derive.rs2
31 files changed, 46 insertions, 46 deletions
diff --git a/.github/ISSUE_TEMPLATE/blank_issue.yml b/.github/ISSUE_TEMPLATE/blank_issue.yml
index d610e8c7bc4..89884bfc859 100644
--- a/.github/ISSUE_TEMPLATE/blank_issue.yml
+++ b/.github/ISSUE_TEMPLATE/blank_issue.yml
@@ -9,7 +9,7 @@ body:
     attributes:
       label: Description
       description: >
-        Please provide a discription of the issue, along with any information
+        Please provide a description of the issue, along with any information
         you feel relevant to replicate it.
     validations:
       required: true
diff --git a/.github/ISSUE_TEMPLATE/false_negative.yml b/.github/ISSUE_TEMPLATE/false_negative.yml
index 9357ccc4f4e..25e436d30b9 100644
--- a/.github/ISSUE_TEMPLATE/false_negative.yml
+++ b/.github/ISSUE_TEMPLATE/false_negative.yml
@@ -23,7 +23,7 @@ body:
     id: reproducer
     attributes:
       label: Reproducer
-      description: Please provide the code and steps to repoduce the bug
+      description: Please provide the code and steps to reproduce the bug
       value: |
         I tried this code:
 
diff --git a/.github/ISSUE_TEMPLATE/false_positive.yml b/.github/ISSUE_TEMPLATE/false_positive.yml
index b7dd400ee73..561b65c93a7 100644
--- a/.github/ISSUE_TEMPLATE/false_positive.yml
+++ b/.github/ISSUE_TEMPLATE/false_positive.yml
@@ -24,7 +24,7 @@ body:
     attributes:
       label: Reproducer
       description: >
-        Please provide the code and steps to repoduce the bug together with the
+        Please provide the code and steps to reproduce the bug together with the
         output from Clippy.
       value: |
         I tried this code:
diff --git a/.github/workflows/clippy.yml b/.github/workflows/clippy.yml
index cd83bc9642b..4292949a02d 100644
--- a/.github/workflows/clippy.yml
+++ b/.github/workflows/clippy.yml
@@ -6,14 +6,14 @@ on:
     branches-ignore:
       - auto
       - try
-    # Don't run Clippy tests, when only textfiles were modified
+    # Don't run Clippy tests, when only text files were modified
     paths-ignore:
     - 'COPYRIGHT'
     - 'LICENSE-*'
     - '**.md'
     - '**.txt'
   pull_request:
-    # Don't run Clippy tests, when only textfiles were modified
+    # Don't run Clippy tests, when only text files were modified
     paths-ignore:
     - 'COPYRIGHT'
     - 'LICENSE-*'
diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs
index 3fbb77d5923..ad4b96f7ff3 100644
--- a/clippy_dev/src/setup/git_hook.rs
+++ b/clippy_dev/src/setup/git_hook.rs
@@ -18,7 +18,7 @@ pub fn install_hook(force_override: bool) {
 
     // So a little bit of a funny story. Git on unix requires the pre-commit file
     // to have the `execute` permission to be set. The Rust functions for modifying
-    // these flags doesn't seem to work when executed with normal user permissions.
+    // these flags doesn't seem to work when executed with normal user permissions. 
     //
     // However, there is a little hack that is also being used by Rust itself in their
     // setup script. Git saves the `execute` flag when syncing files. This means
diff --git a/clippy_dev/src/setup/mod.rs b/clippy_dev/src/setup/mod.rs
index a1e4dd103b8..f691ae4fa45 100644
--- a/clippy_dev/src/setup/mod.rs
+++ b/clippy_dev/src/setup/mod.rs
@@ -7,7 +7,7 @@ use std::path::Path;
 const CLIPPY_DEV_DIR: &str = "clippy_dev";
 
 /// This function verifies that the tool is being executed in the clippy directory.
-/// This is useful to ensure that setups only modify Clippys resources. The verification
+/// This is useful to ensure that setups only modify Clippy's resources. The verification
 /// is done by checking that `clippy_dev` is a sub directory of the current directory.
 ///
 /// It will print an error message and return `false` if the directory could not be
@@ -17,7 +17,7 @@ fn verify_inside_clippy_dir() -> bool {
     if path.exists() && path.is_dir() {
         true
     } else {
-        eprintln!("error: unable to verify that the working directory is clippys directory");
+        eprintln!("error: unable to verify that the working directory is clippy's directory");
         false
     }
 }
diff --git a/clippy_lints/src/casts/mod.rs b/clippy_lints/src/casts/mod.rs
index 55c1f085657..f05315a7d0c 100644
--- a/clippy_lints/src/casts/mod.rs
+++ b/clippy_lints/src/casts/mod.rs
@@ -270,7 +270,7 @@ declare_clippy_lint! {
     ///
     /// ### Why is this bad?
     /// Casting a function pointer to an integer can have surprising results and can occur
-    /// accidentally if parantheses are omitted from a function call. If you aren't doing anything
+    /// accidentally if parentheses are omitted from a function call. If you aren't doing anything
     /// low-level with function pointers then you can opt-out of casting functions to integers in
     /// order to avoid mistakes. Alternatively, you can use this lint to audit all uses of function
     /// pointer casts in your code.
diff --git a/clippy_lints/src/empty_structs_with_brackets.rs b/clippy_lints/src/empty_structs_with_brackets.rs
index fdeac8d8255..8430e7b4c82 100644
--- a/clippy_lints/src/empty_structs_with_brackets.rs
+++ b/clippy_lints/src/empty_structs_with_brackets.rs
@@ -66,7 +66,7 @@ fn has_no_fields(cx: &EarlyContext<'_>, var_data: &VariantData, braces_span: Spa
     }
 
     // there might still be field declarations hidden from the AST
-    // (conditionaly compiled code using #[cfg(..)])
+    // (conditionally compiled code using #[cfg(..)])
 
     let Some(braces_span_str) = snippet_opt(cx, braces_span) else {
         return false;
diff --git a/clippy_lints/src/index_refutable_slice.rs b/clippy_lints/src/index_refutable_slice.rs
index 6b62748ffef..8a84513b779 100644
--- a/clippy_lints/src/index_refutable_slice.rs
+++ b/clippy_lints/src/index_refutable_slice.rs
@@ -116,7 +116,7 @@ fn find_slice_values(cx: &LateContext<'_>, pat: &hir::Pat<'_>) -> FxIndexMap<hir
             let bound_ty = cx.typeck_results().node_type(pat.hir_id);
             if let ty::Slice(inner_ty) | ty::Array(inner_ty, _) = bound_ty.peel_refs().kind() {
                 // The values need to use the `ref` keyword if they can't be copied.
-                // This will need to be adjusted if the lint want to support multable access in the future
+                // This will need to be adjusted if the lint want to support mutable access in the future
                 let src_is_ref = bound_ty.is_ref() && binding != hir::BindingAnnotation::Ref;
                 let needs_ref = !(src_is_ref || is_copy(cx, *inner_ty));
 
diff --git a/clippy_lints/src/match_result_ok.rs b/clippy_lints/src/match_result_ok.rs
index 77a4917ec58..3349b85f134 100644
--- a/clippy_lints/src/match_result_ok.rs
+++ b/clippy_lints/src/match_result_ok.rs
@@ -24,7 +24,7 @@ declare_clippy_lint! {
     ///     vec.push(value)
     /// }
     ///
-    /// if let Some(valie) = iter.next().ok() {
+    /// if let Some(value) = iter.next().ok() {
     ///     vec.push(value)
     /// }
     /// ```
@@ -60,7 +60,7 @@ impl<'tcx> LateLintPass<'tcx> for MatchResultOk {
         if_chain! {
             if let ExprKind::MethodCall(ok_path, [ref result_types_0, ..], _) = let_expr.kind; //check is expr.ok() has type Result<T,E>.ok(, _)
             if let PatKind::TupleStruct(QPath::Resolved(_, x), y, _)  = let_pat.kind; //get operation
-            if method_chain_args(let_expr, &["ok"]).is_some(); //test to see if using ok() methoduse std::marker::Sized;
+            if method_chain_args(let_expr, &["ok"]).is_some(); //test to see if using ok() method use std::marker::Sized;
             if is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(result_types_0), sym::Result);
             if rustc_hir_pretty::to_string(rustc_hir_pretty::NO_ANN, |s| s.print_path(x, false)) == "Some";
 
diff --git a/clippy_lints/src/matches/match_same_arms.rs b/clippy_lints/src/matches/match_same_arms.rs
index b8591fe0db0..9b7344fb8b0 100644
--- a/clippy_lints/src/matches/match_same_arms.rs
+++ b/clippy_lints/src/matches/match_same_arms.rs
@@ -30,7 +30,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) {
         .map(|a| NormalizedPat::from_pat(cx, &arena, a.pat))
         .collect();
 
-    // The furthast forwards a pattern can move without semantic changes
+    // The furthest forwards a pattern can move without semantic changes
     let forwards_blocking_idxs: Vec<_> = normalized_pats
         .iter()
         .enumerate()
@@ -43,7 +43,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) {
         })
         .collect();
 
-    // The furthast backwards a pattern can move without semantic changes
+    // The furthest backwards a pattern can move without semantic changes
     let backwards_blocking_idxs: Vec<_> = normalized_pats
         .iter()
         .enumerate()
diff --git a/clippy_lints/src/matches/mod.rs b/clippy_lints/src/matches/mod.rs
index 854cf06ed81..401ecef460c 100644
--- a/clippy_lints/src/matches/mod.rs
+++ b/clippy_lints/src/matches/mod.rs
@@ -7,7 +7,7 @@ use rustc_semver::RustcVersion;
 use rustc_session::{declare_tool_lint, impl_lint_pass};
 use rustc_span::{Span, SpanData, SyntaxContext};
 
-mod infalliable_detructuring_match;
+mod infallible_destructuring_match;
 mod match_as_ref;
 mod match_bool;
 mod match_like_matches;
@@ -694,7 +694,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches {
     }
 
     fn check_local(&mut self, cx: &LateContext<'tcx>, local: &'tcx Local<'_>) {
-        self.infallible_destructuring_match_linted |= infalliable_detructuring_match::check(cx, local);
+        self.infallible_destructuring_match_linted |= infallible_destructuring_match::check(cx, local);
     }
 
     fn check_pat(&mut self, cx: &LateContext<'tcx>, pat: &'tcx Pat<'_>) {
diff --git a/clippy_lints/src/matches/needless_match.rs b/clippy_lints/src/matches/needless_match.rs
index d6c8e472552..0abe6ddda65 100644
--- a/clippy_lints/src/matches/needless_match.rs
+++ b/clippy_lints/src/matches/needless_match.rs
@@ -118,7 +118,7 @@ fn strip_return<'hir>(expr: &'hir Expr<'hir>) -> &'hir Expr<'hir> {
 }
 
 /// Manually check for coercion casting by checking if the type of the match operand or let expr
-/// differs with the assigned local variable or the funtion return type.
+/// differs with the assigned local variable or the function return type.
 fn expr_ty_matches_p_ty(cx: &LateContext<'_>, expr: &Expr<'_>, p_expr: &Expr<'_>) -> bool {
     if let Some(p_node) = get_parent_node(cx.tcx, p_expr.hir_id) {
         match p_node {
diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs
index f1a74220e68..70a2aaf78a0 100644
--- a/clippy_lints/src/methods/mod.rs
+++ b/clippy_lints/src/methods/mod.rs
@@ -1266,7 +1266,7 @@ declare_clippy_lint! {
     #[clippy::version = "1.55.0"]
     pub EXTEND_WITH_DRAIN,
     perf,
-    "using vec.append(&mut vec) to move the full range of a vecor to another"
+    "using vec.append(&mut vec) to move the full range of a vector to another"
 }
 
 declare_clippy_lint! {
@@ -2100,7 +2100,7 @@ declare_clippy_lint! {
     /// using `.collect::<String>()` over `.collect::<Vec<String>>().join("")`
     /// will prevent loop unrolling and will result in a negative performance impact.
     ///
-    /// Additionlly, differences have been observed between aarch64 and x86_64 assembly output,
+    /// Additionally, differences have been observed between aarch64 and x86_64 assembly output,
     /// with aarch64 tending to producing faster assembly in more cases when using `.collect::<String>()`
     #[clippy::version = "1.61.0"]
     pub UNNECESSARY_JOIN,
diff --git a/clippy_lints/src/missing_inline.rs b/clippy_lints/src/missing_inline.rs
index ac2f16b49e3..6e6ad1ebbce 100644
--- a/clippy_lints/src/missing_inline.rs
+++ b/clippy_lints/src/missing_inline.rs
@@ -44,7 +44,7 @@ declare_clippy_lint! {
     /// pub struct PubBaz;
     /// impl PubBaz {
     ///    fn private() {} // ok
-    ///    pub fn not_ptrivate() {} // missing #[inline]
+    ///    pub fn not_private() {} // missing #[inline]
     /// }
     ///
     /// impl Bar for PubBaz {
diff --git a/clippy_lints/src/needless_bitwise_bool.rs b/clippy_lints/src/needless_bitwise_bool.rs
index a8a8d174a82..95395e2e136 100644
--- a/clippy_lints/src/needless_bitwise_bool.rs
+++ b/clippy_lints/src/needless_bitwise_bool.rs
@@ -53,7 +53,7 @@ fn is_bitwise_operation(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool {
     false
 }
 
-fn suggession_snippet(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option<String> {
+fn suggesstion_snippet(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option<String> {
     if let ExprKind::Binary(ref op, left, right) = expr.kind {
         if let (Some(l_snippet), Some(r_snippet)) = (snippet_opt(cx, left.span), snippet_opt(cx, right.span)) {
             let op_snippet = match op.node {
@@ -75,7 +75,7 @@ impl LateLintPass<'_> for NeedlessBitwiseBool {
                 expr.span,
                 "use of bitwise operator instead of lazy operator between booleans",
                 |diag| {
-                    if let Some(sugg) = suggession_snippet(cx, expr) {
+                    if let Some(sugg) = suggesstion_snippet(cx, expr) {
                         diag.span_suggestion(expr.span, "try", sugg, Applicability::MachineApplicable);
                     }
                 },
diff --git a/clippy_lints/src/needless_late_init.rs b/clippy_lints/src/needless_late_init.rs
index 9957afcbf04..bbcf7e9e378 100644
--- a/clippy_lints/src/needless_late_init.rs
+++ b/clippy_lints/src/needless_late_init.rs
@@ -240,7 +240,7 @@ fn check<'tcx>(
                 cx,
                 NEEDLESS_LATE_INIT,
                 local_stmt.span,
-                "unneeded late initalization",
+                "unneeded late initialization",
                 |diag| {
                     diag.tool_only_span_suggestion(
                         local_stmt.span,
@@ -265,7 +265,7 @@ fn check<'tcx>(
                 cx,
                 NEEDLESS_LATE_INIT,
                 local_stmt.span,
-                "unneeded late initalization",
+                "unneeded late initialization",
                 |diag| {
                     diag.tool_only_span_suggestion(local_stmt.span, "remove the local", String::new(), applicability);
 
@@ -296,7 +296,7 @@ fn check<'tcx>(
                 cx,
                 NEEDLESS_LATE_INIT,
                 local_stmt.span,
-                "unneeded late initalization",
+                "unneeded late initialization",
                 |diag| {
                     diag.tool_only_span_suggestion(local_stmt.span, "remove the local", String::new(), applicability);
 
diff --git a/clippy_lints/src/octal_escapes.rs b/clippy_lints/src/octal_escapes.rs
index c19cea66104..e8532db4f71 100644
--- a/clippy_lints/src/octal_escapes.rs
+++ b/clippy_lints/src/octal_escapes.rs
@@ -25,7 +25,7 @@ declare_clippy_lint! {
     ///
     /// ### Known problems
     /// The actual meaning can be the intended one. `\x00` can be used in these
-    /// cases to be unambigious.
+    /// cases to be unambiguous.
     ///
     /// The lint does not trigger for format strings in `print!()`, `write!()`
     /// and friends since the string is already preprocessed when Clippy lints
diff --git a/clippy_lints/src/option_if_let_else.rs b/clippy_lints/src/option_if_let_else.rs
index c9f807f2aa3..ea5a8f0858b 100644
--- a/clippy_lints/src/option_if_let_else.rs
+++ b/clippy_lints/src/option_if_let_else.rs
@@ -78,7 +78,7 @@ fn is_result_ok(cx: &LateContext<'_>, expr: &'_ Expr<'_>) -> bool {
 
 /// A struct containing information about occurrences of the
 /// `if let Some(..) = .. else` construct that this lint detects.
-struct OptionIfLetElseOccurence {
+struct OptionIfLetElseOccurrence {
     option: String,
     method_sugg: String,
     some_expr: String,
@@ -100,9 +100,9 @@ fn format_option_in_sugg(cx: &LateContext<'_>, cond_expr: &Expr<'_>, as_ref: boo
 }
 
 /// If this expression is the option if let/else construct we're detecting, then
-/// this function returns an `OptionIfLetElseOccurence` struct with details if
+/// this function returns an `OptionIfLetElseOccurrence` struct with details if
 /// this construct is found, or None if this construct is not found.
-fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> Option<OptionIfLetElseOccurence> {
+fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> Option<OptionIfLetElseOccurrence> {
     if_chain! {
         if !expr.span.from_expansion(); // Don't lint macros, because it behaves weirdly
         if !in_constant(cx, expr.hir_id);
@@ -154,7 +154,7 @@ fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) ->
                     }
                 }
             }
-            Some(OptionIfLetElseOccurence {
+            Some(OptionIfLetElseOccurrence {
                 option: format_option_in_sugg(cx, cond_expr, as_ref, as_mut),
                 method_sugg: method_sugg.to_string(),
                 some_expr: format!("|{}{}| {}", capture_mut, capture_name, Sugg::hir_with_macro_callsite(cx, some_body, "..")),
diff --git a/clippy_lints/src/suspicious_operation_groupings.rs b/clippy_lints/src/suspicious_operation_groupings.rs
index b5dd27ff80d..c4c1aa11004 100644
--- a/clippy_lints/src/suspicious_operation_groupings.rs
+++ b/clippy_lints/src/suspicious_operation_groupings.rs
@@ -550,7 +550,7 @@ fn ident_difference_expr_with_base_location(
     // IdentIter, then the output of this function will be almost always be correct
     // in practice.
     //
-    // If it turns out that problematic cases are more prelavent than we assume,
+    // If it turns out that problematic cases are more prevalent than we assume,
     // then we should be able to change this function to do the correct traversal,
     // without needing to change the rest of the code.
 
diff --git a/clippy_lints/src/transmute/utils.rs b/clippy_lints/src/transmute/utils.rs
index 0e07a0b0392..0cbf5ccefa6 100644
--- a/clippy_lints/src/transmute/utils.rs
+++ b/clippy_lints/src/transmute/utils.rs
@@ -87,7 +87,7 @@ fn check_cast<'tcx>(cx: &LateContext<'tcx>, e: &'tcx Expr<'_>, from_ty: Ty<'tcx>
             let res = check.do_check(&fn_ctxt);
 
             // do_check's documentation says that it might return Ok and create
-            // errors in the fcx instead of returing Err in some cases. Those cases
+            // errors in the fcx instead of returning Err in some cases. Those cases
             // should be filtered out before getting here.
             assert!(
                 !fn_ctxt.errors_reported_since_creation(),
diff --git a/clippy_lints/src/types/mod.rs b/clippy_lints/src/types/mod.rs
index 67cc8913318..b1b2addb9a1 100644
--- a/clippy_lints/src/types/mod.rs
+++ b/clippy_lints/src/types/mod.rs
@@ -432,7 +432,7 @@ impl Types {
     fn check_fn_decl(&mut self, cx: &LateContext<'_>, decl: &FnDecl<'_>, context: CheckTyContext) {
         // Ignore functions in trait implementations as they are usually forced by the trait definition.
         //
-        // FIXME: idially we would like to warn *if the compicated type can be simplified*, but it's hard to
+        // FIXME: ideally we would like to warn *if the complicated type can be simplified*, but it's hard to
         // check.
         if context.is_in_trait_impl {
             return;
diff --git a/clippy_lints/src/unnested_or_patterns.rs b/clippy_lints/src/unnested_or_patterns.rs
index 790ffe618d7..ae431aac83b 100644
--- a/clippy_lints/src/unnested_or_patterns.rs
+++ b/clippy_lints/src/unnested_or_patterns.rs
@@ -25,7 +25,7 @@ declare_clippy_lint! {
     /// *disjunctive normal form (DNF)* into *conjunctive normal form (CNF)*.
     ///
     /// ### Why is this bad?
-    /// In the example above, `Some` is repeated, which unncessarily complicates the pattern.
+    /// In the example above, `Some` is repeated, which unnecessarily complicates the pattern.
     ///
     /// ### Example
     /// ```rust
diff --git a/clippy_lints/src/use_self.rs b/clippy_lints/src/use_self.rs
index f8e1021af0e..138f8bccb3f 100644
--- a/clippy_lints/src/use_self.rs
+++ b/clippy_lints/src/use_self.rs
@@ -30,7 +30,7 @@ declare_clippy_lint! {
     ///
     /// ### Known problems
     /// - Unaddressed false negative in fn bodies of trait implementations
-    /// - False positive with assotiated types in traits (#4140)
+    /// - False positive with associated types in traits (#4140)
     ///
     /// ### Example
     /// ```rust
diff --git a/clippy_lints/src/utils/author.rs b/clippy_lints/src/utils/author.rs
index d23c85c033b..ff5be825b78 100644
--- a/clippy_lints/src/utils/author.rs
+++ b/clippy_lints/src/utils/author.rs
@@ -70,7 +70,7 @@ macro_rules! bind {
     };
 }
 
-/// Transforms the given `Option<T>` varibles into `OptionPat<Binding<T>>`.
+/// Transforms the given `Option<T>` variables into `OptionPat<Binding<T>>`.
 /// This displays as `Some($name)` or `None` when printed. The name of the inner binding
 /// is set to the name of the variable passed to the macro.
 macro_rules! opt_bind {
diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs
index 25d74b8c499..0e8f40e9210 100644
--- a/clippy_lints/src/utils/internal_lints.rs
+++ b/clippy_lints/src/utils/internal_lints.rs
@@ -292,7 +292,7 @@ declare_clippy_lint! {
     /// Checks for unnecessary conversion from Symbol to a string.
     ///
     /// ### Why is this bad?
-    /// It's faster use symbols directly intead of strings.
+    /// It's faster use symbols directly instead of strings.
     ///
     /// ### Example
     /// Bad:
@@ -823,7 +823,7 @@ fn suggest_note(
         cx,
         COLLAPSIBLE_SPAN_LINT_CALLS,
         expr.span,
-        "this call is collspible",
+        "this call is collapsible",
         "collapse into",
         format!(
             "span_lint_and_note({}, {}, {}, {}, {}, {})",
diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs
index ca03b8010dd..526bb2f7e06 100644
--- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs
+++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs
@@ -117,7 +117,7 @@ const APPLICABILITY_NAME_INDEX: usize = 2;
 /// This applicability will be set for unresolved applicability values.
 const APPLICABILITY_UNRESOLVED_STR: &str = "Unresolved";
 /// The version that will be displayed if none has been defined
-const VERION_DEFAULT_STR: &str = "Unknown";
+const VERSION_DEFAULT_STR: &str = "Unknown";
 
 declare_clippy_lint! {
     /// ### What it does
@@ -571,7 +571,7 @@ fn extract_attr_docs(cx: &LateContext<'_>, item: &Item<'_>) -> Option<String> {
 
 fn get_lint_version(cx: &LateContext<'_>, item: &Item<'_>) -> String {
     extract_clippy_version_value(cx, item).map_or_else(
-        || VERION_DEFAULT_STR.to_string(),
+        || VERSION_DEFAULT_STR.to_string(),
         |version| version.as_str().to_string(),
     )
 }
@@ -872,7 +872,7 @@ impl<'a, 'hir> IsMultiSpanScanner<'a, 'hir> {
         self.suggestion_count += 2;
     }
 
-    /// Checks if the suggestions include multiple spanns
+    /// Checks if the suggestions include multiple spans
     fn is_multi_part(&self) -> bool {
         self.suggestion_count > 1
     }
diff --git a/clippy_utils/src/macros.rs b/clippy_utils/src/macros.rs
index e7d4c5a4952..a268e339bb1 100644
--- a/clippy_utils/src/macros.rs
+++ b/clippy_utils/src/macros.rs
@@ -367,7 +367,7 @@ impl<'tcx> FormatArgsExpn<'tcx> {
         expr_visitor_no_bodies(|e| {
             // if we're still inside of the macro definition...
             if e.span.ctxt() == expr.span.ctxt() {
-                // ArgumnetV1::new_<format_trait>(<value>)
+                // ArgumentV1::new_<format_trait>(<value>)
                 if_chain! {
                     if let ExprKind::Call(callee, [val]) = e.kind;
                     if let ExprKind::Path(QPath::TypeRelative(ty, seg)) = callee.kind;
diff --git a/clippy_utils/src/source.rs b/clippy_utils/src/source.rs
index beed7326803..c69a3d8d2a1 100644
--- a/clippy_utils/src/source.rs
+++ b/clippy_utils/src/source.rs
@@ -108,7 +108,7 @@ pub fn is_present_in_source<T: LintContext>(cx: &T, span: Span) -> bool {
     true
 }
 
-/// Returns the positon just before rarrow
+/// Returns the position just before rarrow
 ///
 /// ```rust,ignore
 /// fn into(self) -> () {}
diff --git a/tests/lint_message_convention.rs b/tests/lint_message_convention.rs
index dc82ba891fb..dd1d4412036 100644
--- a/tests/lint_message_convention.rs
+++ b/tests/lint_message_convention.rs
@@ -66,7 +66,7 @@ fn lint_message_convention() {
 
     // make sure that lint messages:
     // * are not capitalized
-    // * don't have puncuation at the end of the last sentence
+    // * don't have punctuation at the end of the last sentence
 
     // these directories have interesting tests
     let test_dirs = ["ui", "ui-cargo", "ui-internal", "ui-toml"]
diff --git a/tests/ui/auxiliary/proc_macro_derive.rs b/tests/ui/auxiliary/proc_macro_derive.rs
index 4b7b7fec78f..ed7b17651e6 100644
--- a/tests/ui/auxiliary/proc_macro_derive.rs
+++ b/tests/ui/auxiliary/proc_macro_derive.rs
@@ -13,7 +13,7 @@ use proc_macro::{quote, TokenStream};
 
 #[proc_macro_derive(DeriveSomething)]
 pub fn derive(_: TokenStream) -> TokenStream {
-    // Shound not trigger `used_underscore_binding`
+    // Should not trigger `used_underscore_binding`
     let _inside_derive = 1;
     assert_eq!(_inside_derive, _inside_derive);