blob: c7127db904a3806b7da722b2d7a62651cf12c0a1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
if_chain! {
if let ExprKind::Block(ref block) = expr.kind;
if let Some(trailing_expr) = &block.expr;
if block.stmts.len() == 1;
if let StmtKind::Semi(ref e, _) = block.stmts[0].kind
if let ExprKind::Tup(ref elements) = e.kind;
if elements.len() == 0;
then {
// report your lint here
}
}
if_chain! {
then {
// report your lint here
}
}
|