match expr.node {
hir::ExprBinary(ref op, ref l, ref r) => {
match op.node {
- hir::BiRem | hir::BiAnd | hir::BiOr | hir::BiBitAnd |
+ hir::BiAnd | hir::BiOr | hir::BiBitAnd |
hir::BiBitOr | hir::BiBitXor | hir::BiShl | hir::BiShr |
hir::BiEq | hir::BiLt | hir::BiLe | hir::BiNe | hir::BiGe |
hir::BiGt => return,
1 + i; //~ERROR integer arithmetic detected
i * 2; //~ERROR integer arithmetic detected
1 % //~ERROR integer arithmetic detected
- i / 2;
+ i / 2; // no error, this is part of the expression in the preceding line
i - 2 + 2 - i; //~ERROR integer arithmetic detected
-i; //~ERROR integer arithmetic detected