Skip to content

allowing dead code should be transitive #11380

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
metajack opened this issue Jan 7, 2014 · 3 comments · Fixed by #11471
Closed

allowing dead code should be transitive #11380

metajack opened this issue Jan 7, 2014 · 3 comments · Fixed by #11471
Labels
A-lints Area: Lints (warnings about flaws in source code) such as unused_mut.

Comments

@metajack
Copy link
Contributor

metajack commented Jan 7, 2014

Currently if you have some dead_code and you want to preserve it, you have to annotate every function you want to preserve and all the dead code that function calls.

I think we should consider annotated code to be alive, and then all the code that touches to be alive as well.

@alexcrichton
Copy link
Member

cc @ktt3ja, sounds like a cool idea to me.

@ktt3ja
Copy link
Contributor

ktt3ja commented Jan 10, 2014

By "annotate", do you mean putting an #[allow(dead_code)] attribute above the function you want to preserve?

@metajack
Copy link
Contributor Author

@ktt3ja yes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-lints Area: Lints (warnings about flaws in source code) such as unused_mut.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants