mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-24 05:33:27 +00:00
Fix some typos
This commit is contained in:
parent
71777465cc
commit
7062a013e7
3 changed files with 5 additions and 5 deletions
|
@ -124,7 +124,7 @@ impl<'tcx> LateLintPass<'tcx> for MissingConstForFn {
|
|||
FnKind::Method(_, sig, ..) => {
|
||||
if trait_ref_of_method(cx, def_id).is_some()
|
||||
|| already_const(sig.header)
|
||||
|| method_accepts_dropable(cx, sig.decl.inputs)
|
||||
|| method_accepts_droppable(cx, sig.decl.inputs)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
@ -159,7 +159,7 @@ impl<'tcx> LateLintPass<'tcx> for MissingConstForFn {
|
|||
|
||||
/// Returns true if any of the method parameters is a type that implements `Drop`. The method
|
||||
/// can't be made const then, because `drop` can't be const-evaluated.
|
||||
fn method_accepts_dropable(cx: &LateContext<'_>, param_tys: &[hir::Ty<'_>]) -> bool {
|
||||
fn method_accepts_droppable(cx: &LateContext<'_>, param_tys: &[hir::Ty<'_>]) -> bool {
|
||||
// If any of the params are droppable, return true
|
||||
param_tys.iter().any(|hir_ty| {
|
||||
let ty_ty = hir_ty_to_ty(cx.tcx, hir_ty);
|
||||
|
|
|
@ -569,7 +569,7 @@ fn check_invalid_clippy_version_attribute(cx: &LateContext<'_>, item: &'_ Item<'
|
|||
item.span,
|
||||
"this item has an invalid `clippy::version` attribute",
|
||||
None,
|
||||
"please use a valid sematic version, see `doc/adding_lints.md`",
|
||||
"please use a valid semantic version, see `doc/adding_lints.md`",
|
||||
);
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -16,7 +16,7 @@ note: the lint level is defined here
|
|||
LL | #![deny(clippy::internal)]
|
||||
| ^^^^^^^^^^^^^^^^
|
||||
= note: `#[deny(clippy::invalid_clippy_version_attribute)]` implied by `#[deny(clippy::internal)]`
|
||||
= help: please use a valid sematic version, see `doc/adding_lints.md`
|
||||
= help: please use a valid senmatic version, see `doc/adding_lints.md`
|
||||
= note: this error originates in the macro `$crate::declare_tool_lint` which comes from the expansion of the macro `declare_tool_lint` (in Nightly builds, run with -Z macro-backtrace for more info)
|
||||
|
||||
error: this item has an invalid `clippy::version` attribute
|
||||
|
@ -31,7 +31,7 @@ LL | | report_in_external_macro: true
|
|||
LL | | }
|
||||
| |_^
|
||||
|
|
||||
= help: please use a valid sematic version, see `doc/adding_lints.md`
|
||||
= help: please use a valid semantic version, see `doc/adding_lints.md`
|
||||
= note: this error originates in the macro `$crate::declare_tool_lint` which comes from the expansion of the macro `declare_tool_lint` (in Nightly builds, run with -Z macro-backtrace for more info)
|
||||
|
||||
error: this lint is missing the `clippy::version` attribute or version value
|
||||
|
|
Loading…
Reference in a new issue