Update clippy_lints/src/methods/bytes_nth.rs
Co-authored-by: Phil Hansch <dev@phansch.net>
This commit is contained in:
parent
1c3033d5cf
commit
932cc085e6
@ -26,7 +26,7 @@ pub(super) fn lints<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'_>, iter_args: &'
|
||||
BYTES_NTH,
|
||||
expr.span,
|
||||
&format!("called `.byte().nth()` on a `{}`", caller_type),
|
||||
"try calling `.as_bytes().get()`",
|
||||
"try",
|
||||
format!(
|
||||
"{}.as_bytes().get({})",
|
||||
snippet_with_applicability(cx, iter_args[0].span, "..", &mut applicability),
|
||||
|
Loading…
x
Reference in New Issue
Block a user