2023-04-20 14:37:15 +00:00
|
|
|
//@run-rustfix
|
2019-08-22 07:18:08 +02:00
|
|
|
|
|
|
|
#![warn(clippy::short_circuit_statement)]
|
|
|
|
#![allow(clippy::nonminimal_bool)]
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
if f() { g(); }
|
|
|
|
if !f() { g(); }
|
2021-12-11 02:32:23 +09:00
|
|
|
if 1 != 2 { g(); }
|
2019-08-22 07:18:08 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
fn f() -> bool {
|
|
|
|
true
|
|
|
|
}
|
|
|
|
|
|
|
|
fn g() -> bool {
|
|
|
|
false
|
|
|
|
}
|