2023-07-02 07:35:19 -05:00
|
|
|
error: this function is only used once
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/single_call_fn.rs:13:1
|
|
|
|
|
|
|
|
|
LL | fn i() {}
|
|
|
|
| ^^^^^^^^^
|
|
|
|
|
|
|
|
|
note: used here
|
|
|
|
--> tests/ui/single_call_fn.rs:18:13
|
|
|
|
|
|
|
|
|
LL | let a = i;
|
|
|
|
| ^
|
|
|
|
= note: `-D clippy::single-call-fn` implied by `-D warnings`
|
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::single_call_fn)]`
|
|
|
|
|
|
|
|
error: this function is only used once
|
|
|
|
--> tests/ui/single_call_fn.rs:14:1
|
|
|
|
|
|
|
|
|
LL | fn j() {}
|
|
|
|
| ^^^^^^^^^
|
|
|
|
|
|
|
|
|
note: used here
|
|
|
|
--> tests/ui/single_call_fn.rs:25:9
|
|
|
|
|
|
|
|
|
LL | j();
|
|
|
|
| ^
|
|
|
|
|
|
|
|
error: this function is only used once
|
|
|
|
--> tests/ui/single_call_fn.rs:34:1
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
|
|
|
LL | / fn c() {
|
|
|
|
LL | | println!("really");
|
|
|
|
LL | | println!("long");
|
|
|
|
LL | | println!("function...");
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
note: used here
|
|
|
|
--> tests/ui/single_call_fn.rs:41:5
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
|
|
|
LL | c();
|
|
|
|
| ^
|
|
|
|
|
|
|
|
error: this function is only used once
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/single_call_fn.rs:44:1
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
LL | fn a() {}
|
2023-07-02 07:35:19 -05:00
|
|
|
| ^^^^^^^^^
|
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
note: used here
|
|
|
|
--> tests/ui/single_call_fn.rs:47:5
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
LL | a();
|
|
|
|
| ^
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
|
|
error: this function is only used once
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/single_call_fn.rs:89:5
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
LL | fn default() {}
|
|
|
|
| ^^^^^^^^^^^^^^^
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
note: used here
|
|
|
|
--> tests/ui/single_call_fn.rs:104:5
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
LL | T::default();
|
|
|
|
| ^^^^^^^^^^
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
|
|
error: this function is only used once
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/single_call_fn.rs:102:9
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
LL | fn foo() {}
|
|
|
|
| ^^^^^^^^^^^
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
note: used here
|
|
|
|
--> tests/ui/single_call_fn.rs:105:5
|
2023-07-02 07:35:19 -05:00
|
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
LL | S::foo();
|
|
|
|
| ^^^^^^
|
2023-07-02 07:35:19 -05:00
|
|
|
|
2024-02-27 08:25:18 -06:00
|
|
|
error: aborting due to 6 previous errors
|
2023-07-02 07:35:19 -05:00
|
|
|
|