1
Fork 0
This commit is contained in:
csmoe 2018-07-12 15:30:57 +08:00 committed by Oliver Schneider
parent 2a016890a0
commit 1bd17e4fa2
90 changed files with 777 additions and 777 deletions

View file

@ -32,7 +32,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for Pass {
fn check_expr(&mut self, cx: &LateContext<'a, 'tcx>, expr: &'tcx Expr) {
// check for instances of 0.0/0.0
if_chain! {
if let ExprBinary(ref op, ref left, ref right) = expr.node;
if let ExprKind::Binary(ref op, ref left, ref right) = expr.node;
if let BinOp_::BiDiv = op.node;
// TODO - constant_simple does not fold many operations involving floats.
// That's probably fine for this lint - it's pretty unlikely that someone would