-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Open
Labels
A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.Area: Lints (warnings about flaws in source code) such as unused_mut.C-bugCategory: This is a bug.Category: This is a bug.I-needs-decisionIssue: In need of a decision.Issue: In need of a decision.
Description
Hi everybody.
Playground
Code:
fn foo() {}
fn bar() {
foo();
}
fn main() {}
Output:
warning: function is never used: `foo`, #[warn(dead_code)] on by default
--> <anon>:1:1
|
1 | fn foo() {
| _^ starting here...
2 | |
3 | | }
| |_^ ...ending here
warning: function is never used: `bar`, #[warn(dead_code)] on by default
--> <anon>:5:1
|
5 | fn bar() {
| _^ starting here...
6 | | foo();
7 | | }
| |_^ ...ending here
I don't like it because it confuses what exactly isn't used.
est31, dhardy, tkaitchuck, frececroka, WiSaGaN and 6 more
Metadata
Metadata
Assignees
Labels
A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.Area: Lints (warnings about flaws in source code) such as unused_mut.C-bugCategory: This is a bug.Category: This is a bug.I-needs-decisionIssue: In need of a decision.Issue: In need of a decision.