1 error: the function has a cognitive complexity of 28
2 --> $DIR/cognitive_complexity.rs:6:1
13 = note: `-D clippy::cognitive-complexity` implied by `-D warnings`
14 = help: you could split it up into multiple smaller functions
16 error: the function has a cognitive complexity of 7
17 --> $DIR/cognitive_complexity.rs:91:1
21 LL | | 'a: for i in 0..20 {
22 LL | | 'b: for j in i..20 {
28 = help: you could split it up into multiple smaller functions
30 error: the function has a cognitive complexity of 1
31 --> $DIR/cognitive_complexity.rs:137:1
33 LL | / fn lots_of_short_circuits() -> bool {
34 LL | | true && false && true && false && true && false && true
38 = help: you could split it up into multiple smaller functions
40 error: the function has a cognitive complexity of 1
41 --> $DIR/cognitive_complexity.rs:142:1
43 LL | / fn lots_of_short_circuits2() -> bool {
44 LL | | true || false || true || false || true || false || true
48 = help: you could split it up into multiple smaller functions
50 error: the function has a cognitive complexity of 2
51 --> $DIR/cognitive_complexity.rs:147:1
54 LL | | let x = || match 99 {
62 = help: you could split it up into multiple smaller functions
64 error: the function has a cognitive complexity of 2
65 --> $DIR/cognitive_complexity.rs:148:13
67 LL | let x = || match 99 {
77 = help: you could split it up into multiple smaller functions
79 error: the function has a cognitive complexity of 2
80 --> $DIR/cognitive_complexity.rs:165:1
84 LL | | 0 => println!("hi"),
85 LL | | _ => println!("bye"),
90 = help: you could split it up into multiple smaller functions
92 error: the function has a cognitive complexity of 2
93 --> $DIR/cognitive_complexity.rs:184:1
97 LL | | 0 => println!("hi"),
98 LL | | 1 => println!("bla"),
104 = help: you could split it up into multiple smaller functions
106 error: the function has a cognitive complexity of 3
107 --> $DIR/cognitive_complexity.rs:194:1
111 LL | | 0 => println!("hi"),
112 LL | | 1 => println!("bla"),
118 = help: you could split it up into multiple smaller functions
120 error: the function has a cognitive complexity of 2
121 --> $DIR/cognitive_complexity.rs:210:1
125 LL | | 0 => println!("hi"),
126 LL | | 1 => panic!("bla"),
132 = help: you could split it up into multiple smaller functions
134 error: the function has a cognitive complexity of 3
135 --> $DIR/cognitive_complexity.rs:220:1
139 LL | | 0 => println!("hi"),
140 LL | | 1 => panic!("bla"),
146 = help: you could split it up into multiple smaller functions
148 error: the function has a cognitive complexity of 2
149 --> $DIR/cognitive_complexity.rs:236:1
153 LL | | 0 => println!("hi"),
154 LL | | 1 => println!("bla"),
160 = help: you could split it up into multiple smaller functions
162 error: the function has a cognitive complexity of 3
163 --> $DIR/cognitive_complexity.rs:246:1
165 LL | / fn barrrr2() {
167 LL | | 0 => println!("hi"),
168 LL | | 1 => println!("bla"),
174 = help: you could split it up into multiple smaller functions
176 error: the function has a cognitive complexity of 2
177 --> $DIR/cognitive_complexity.rs:262:1
181 LL | | println!("yea");
184 LL | | println!("whee");
188 = help: you could split it up into multiple smaller functions
190 error: the function has a cognitive complexity of 4
191 --> $DIR/cognitive_complexity.rs:272:1
193 LL | / pub fn read_file(input_path: &str) -> String {
194 LL | | use std::fs::File;
195 LL | | use std::io::{Read, Write};
196 LL | | use std::path::Path;
202 = help: you could split it up into multiple smaller functions
204 error: the function has a cognitive complexity of 1
205 --> $DIR/cognitive_complexity.rs:303:1
207 LL | / fn void(void: Void) {
214 = help: you could split it up into multiple smaller functions
216 error: the function has a cognitive complexity of 1
217 --> $DIR/cognitive_complexity.rs:316:1
219 LL | / fn try_() -> Result<i32, &'static str> {
222 LL | | _ => return Err("bla"),
227 = help: you could split it up into multiple smaller functions
229 error: the function has a cognitive complexity of 1
230 --> $DIR/cognitive_complexity.rs:324:1
232 LL | / fn try_again() -> Result<i32, &'static str> {
233 LL | | let _ = r#try!(Ok(42));
234 LL | | let _ = r#try!(Ok(43));
235 LL | | let _ = r#try!(Ok(44));
241 = help: you could split it up into multiple smaller functions
243 error: the function has a cognitive complexity of 1
244 --> $DIR/cognitive_complexity.rs:340:1
246 LL | / fn early() -> Result<i32, &'static str> {
255 = help: you could split it up into multiple smaller functions
257 error: the function has a cognitive complexity of 8
258 --> $DIR/cognitive_complexity.rs:354:1
260 LL | / fn early_ret() -> i32 {
261 LL | | let a = if true { 42 } else { return 0; };
262 LL | | let a = if a < 99 { 42 } else { return 0; };
263 LL | | let a = if a < 99 { 42 } else { return 0; };
269 = help: you could split it up into multiple smaller functions
271 error: aborting due to 20 previous errors