Skip to content

Commit

Permalink
Fix some typos
Browse files Browse the repository at this point in the history
Signed-off-by: cui fliter <[email protected]>
  • Loading branch information
cuishuang committed Oct 29, 2023
1 parent 5852ca8 commit 2030c58
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion clippy_lints/src/attrs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ declare_clippy_lint! {
///
/// ### Why is this bad?
/// Misspelling `feature` as `features` can be sometimes hard to spot. It
/// may cause conditional compilation not work quitely.
/// may cause conditional compilation not work quietly.
///
/// ### Example
/// ```no_run
Expand Down
6 changes: 3 additions & 3 deletions clippy_lints/src/from_over_into.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,12 @@ impl<'tcx> LateLintPass<'tcx> for FromOverInto {
extract_msrv_attr!(LateContext);
}

/// Finds the occurences of `Self` and `self`
/// Finds the occurrences of `Self` and `self`
struct SelfFinder<'a, 'tcx> {
cx: &'a LateContext<'tcx>,
/// Occurences of `Self`
/// Occurrences of `Self`
upper: Vec<Span>,
/// Occurences of `self`
/// Occurrences of `self`
lower: Vec<Span>,
/// If any of the `self`/`Self` usages were from an expansion, or the body contained a binding
/// already named `val`
Expand Down
2 changes: 1 addition & 1 deletion clippy_lints/src/matches/single_match.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ pub(crate) fn check(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], expr:
// block with 2+ statements or 1 expr and 1+ statement
Some(els)
} else {
// not a block or an emtpy block w/ comments, don't lint
// not a block or an empty block w/ comments, don't lint
return;
};

Expand Down
2 changes: 1 addition & 1 deletion clippy_lints/src/reserve_after_initialization.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ declare_clippy_lint! {
#[clippy::version = "1.73.0"]
pub RESERVE_AFTER_INITIALIZATION,
complexity,
"`reserve` called immediatly after `Vec` creation"
"`reserve` called immediately after `Vec` creation"
}
impl_lint_pass!(ReserveAfterInitialization => [RESERVE_AFTER_INITIALIZATION]);

Expand Down
2 changes: 1 addition & 1 deletion clippy_lints/src/unnecessary_map_on_constructor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use rustc_span::sym;

declare_clippy_lint! {
/// ### What it does
/// Suggest removing the use of a may (or map_err) method when an Option or Result is being construted.
/// Suggest removing the use of a may (or map_err) method when an Option or Result is being constructed.
///
/// ### Why is this bad?
/// It introduces unnecessary complexity. In this case the function can be used directly and
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ declare_clippy_lint! {
/// Checks if lint formulations have a standardized format.
///
/// ### Why is this bad?
/// It's not neccessarily bad, but we try to enforce a standard in Clippy.
/// It's not necessarily bad, but we try to enforce a standard in Clippy.
///
/// ### Example
/// `Checks for use...` can be written as `Checks for usage...` .
Expand Down

0 comments on commit 2030c58

Please sign in to comment.