]> git.proxmox.com Git - rustc.git/blame - src/tools/clippy/clippy_lints/src/methods/chars_next_cmp_with_unwrap.rs
New upstream version 1.67.1+dfsg1
[rustc.git] / src / tools / clippy / clippy_lints / src / methods / chars_next_cmp_with_unwrap.rs
CommitLineData
cdc7bbd5
XL
1use rustc_lint::LateContext;
2
3use super::CHARS_NEXT_CMP;
4
5/// Checks for the `CHARS_NEXT_CMP` lint with `unwrap()`.
487cf647 6pub(super) fn check(cx: &LateContext<'_>, info: &crate::methods::BinaryExprInfo<'_>) -> bool {
cdc7bbd5
XL
7 crate::methods::chars_cmp_with_unwrap::check(cx, info, &["chars", "next", "unwrap"], CHARS_NEXT_CMP, "starts_with")
8}