blob: f2c6b3f807f1b35a398db13e4c3598f09383912f [file] [log] [blame] [edit]
if let ExprKind::Repeat(value, length) = expr.kind
&& let ExprKind::Lit(ref lit) = value.kind
&& let LitKind::Int(1, LitIntType::Unsigned(UintTy::U8)) = lit.node
&& let ConstArgKind::Anon(anon_const) = length.kind
&& expr1 = &cx.tcx.hir_body(anon_const.body).value
&& let ExprKind::Lit(ref lit1) = expr1.kind
&& let LitKind::Int(5, LitIntType::Unsuffixed) = lit1.node
{
// report your lint here
}