Formatted updates to lints

This commit is contained in:
JarredAllen 2020-07-01 11:41:11 -07:00
parent 6e2d55c8db
commit 1c32263176

View file

@ -87,10 +87,12 @@ fn fetch_const<'a>(cx: &LateContext<'_>, args: &'a [Expr<'a>], m: MinMax) -> Opt
return None; return None;
} }
constant_simple(cx, cx.tables, &args[0]).map_or_else( constant_simple(cx, cx.tables, &args[0]).map_or_else(
|| if let Some(c) = constant_simple(cx, cx.tables(), &args[1]) { || {
Some((m, c, &args[0])) if let Some(c) = constant_simple(cx, cx.tables(), &args[1]) {
} else { Some((m, c, &args[0]))
None } else {
None
}
}, },
|c| { |c| {
if constant_simple(cx, cx.tables, &args[1]).is_none() { if constant_simple(cx, cx.tables, &args[1]).is_none() {
@ -99,5 +101,6 @@ fn fetch_const<'a>(cx: &LateContext<'_>, args: &'a [Expr<'a>], m: MinMax) -> Opt
} else { } else {
None None
} }
}) },
)
} }