2024-06-13 05:30:48 -05:00
|
|
|
if let StmtKind::Let(local) = stmt.kind
|
2022-10-23 08:18:45 -05:00
|
|
|
&& let Some(init) = local.init
|
|
|
|
&& let ExprKind::Call(func, args) = init.kind
|
|
|
|
&& let ExprKind::Path(ref qpath) = func.kind
|
|
|
|
&& match_qpath(qpath, &["{{root}}", "std", "cmp", "min"])
|
|
|
|
&& args.len() == 2
|
|
|
|
&& let ExprKind::Lit(ref lit) = args[0].kind
|
|
|
|
&& let LitKind::Int(3, LitIntType::Unsuffixed) = lit.node
|
|
|
|
&& let ExprKind::Lit(ref lit1) = args[1].kind
|
|
|
|
&& let LitKind::Int(4, LitIntType::Unsuffixed) = lit1.node
|
|
|
|
&& let PatKind::Wild = local.pat.kind
|
|
|
|
{
|
|
|
|
// report your lint here
|
2018-05-27 09:04:28 -05:00
|
|
|
}
|