165 lines
4.5 KiB
Plaintext
165 lines
4.5 KiB
Plaintext
error: the function has a cognitive complexity of (28/25)
|
|
--> tests/ui/cognitive_complexity.rs:6:4
|
|
|
|
|
LL | fn main() {
|
|
| ^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
= note: `-D clippy::cognitive-complexity` implied by `-D warnings`
|
|
= help: to override `-D warnings` add `#[allow(clippy::cognitive_complexity)]`
|
|
|
|
error: the function has a cognitive complexity of (7/1)
|
|
--> tests/ui/cognitive_complexity.rs:93:4
|
|
|
|
|
LL | fn kaboom() {
|
|
| ^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:153:4
|
|
|
|
|
LL | fn baa() {
|
|
| ^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:156:13
|
|
|
|
|
LL | let x = || match 99 {
|
|
| ^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:174:4
|
|
|
|
|
LL | fn bar() {
|
|
| ^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:187:4
|
|
|
|
|
LL | fn dont_warn_on_tests() {
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:197:4
|
|
|
|
|
LL | fn barr() {
|
|
| ^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (3/1)
|
|
--> tests/ui/cognitive_complexity.rs:209:4
|
|
|
|
|
LL | fn barr2() {
|
|
| ^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:227:4
|
|
|
|
|
LL | fn barrr() {
|
|
| ^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (3/1)
|
|
--> tests/ui/cognitive_complexity.rs:239:4
|
|
|
|
|
LL | fn barrr2() {
|
|
| ^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:257:4
|
|
|
|
|
LL | fn barrrr() {
|
|
| ^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (3/1)
|
|
--> tests/ui/cognitive_complexity.rs:269:4
|
|
|
|
|
LL | fn barrrr2() {
|
|
| ^^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:287:4
|
|
|
|
|
LL | fn cake() {
|
|
| ^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (4/1)
|
|
--> tests/ui/cognitive_complexity.rs:299:8
|
|
|
|
|
LL | pub fn read_file(input_path: &str) -> String {
|
|
| ^^^^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:332:4
|
|
|
|
|
LL | fn void(void: Void) {
|
|
| ^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (8/1)
|
|
--> tests/ui/cognitive_complexity.rs:385:4
|
|
|
|
|
LL | fn early_ret() -> i32 {
|
|
| ^^^^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:408:13
|
|
|
|
|
LL | let x = |a: i32, b: i32| -> i32 {
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:423:8
|
|
|
|
|
LL | fn moo(&self) {
|
|
| ^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:434:14
|
|
|
|
|
LL | async fn a() {
|
|
| ^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: the function has a cognitive complexity of (2/1)
|
|
--> tests/ui/cognitive_complexity.rs:443:22
|
|
|
|
|
LL | pub async fn async_method() {
|
|
| ^^^^^^^^^^^^
|
|
|
|
|
= help: you could split it up into multiple smaller functions
|
|
|
|
error: aborting due to 20 previous errors
|
|
|