diff options
| author | Grisha Vartanyan <grisha@vartanyan.com> | 2022-03-25 15:05:27 +0100 |
|---|---|---|
| committer | Grisha Vartanyan <grisha@vartanyan.com> | 2022-03-25 15:05:27 +0100 |
| commit | c3840c9ea142c80107067869143192498beec3d2 (patch) | |
| tree | 48cb5279e3510a73d512df8a2a901504d436ec7d | |
| parent | b51f20eaf5cc311ca601643306ec2ee0c8a714e8 (diff) | |
| download | rust-c3840c9ea142c80107067869143192498beec3d2.tar.gz rust-c3840c9ea142c80107067869143192498beec3d2.zip | |
Update clippy helper function types
| -rw-r--r-- | src/tools/clippy/clippy_lints/src/regex.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/clippy/clippy_lints/src/regex.rs b/src/tools/clippy/clippy_lints/src/regex.rs index b6d04334de9..a92097e1d24 100644 --- a/src/tools/clippy/clippy_lints/src/regex.rs +++ b/src/tools/clippy/clippy_lints/src/regex.rs @@ -81,7 +81,7 @@ impl<'tcx> LateLintPass<'tcx> for Regex { #[allow(clippy::cast_possible_truncation)] // truncation very unlikely here #[must_use] -fn str_span(base: Span, c: regex_syntax::ast::Span, offset: u16) -> Span { +fn str_span(base: Span, c: regex_syntax::ast::Span, offset: u8) -> Span { let offset = u32::from(offset); let end = base.lo() + BytePos(u32::try_from(c.end.offset).expect("offset too large") + offset); let start = base.lo() + BytePos(u32::try_from(c.start.offset).expect("offset too large") + offset); |
