2020-05-28 08:45:24 -05:00
|
|
|
#![warn(unused, clippy::cognitive_complexity)]
|
|
|
|
#![allow(unused_crate_dependencies)]
|
2016-11-02 04:29:57 -05:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
kaboom();
|
|
|
|
}
|
|
|
|
|
2019-02-22 19:19:50 -06:00
|
|
|
#[clippy::cognitive_complexity = "0"]
|
2017-02-08 07:58:07 -06:00
|
|
|
fn kaboom() {
|
2023-08-24 14:32:12 -05:00
|
|
|
//~^ ERROR: the function has a cognitive complexity of (3/0)
|
2016-11-02 04:29:57 -05:00
|
|
|
if 42 == 43 {
|
|
|
|
panic!();
|
|
|
|
} else if "cake" == "lie" {
|
|
|
|
println!("what?");
|
|
|
|
}
|
|
|
|
}
|