-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
add new lint [once_cell_lazy
] to detect usage of static Lazy
type
#12968
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for taking this on!
On my phone, so haven't looked at the implementation much yet. Just some minor changes so far.
@rustbot author
@rustbot ready |
… from `once_cell`
☔ The latest upstream changes (presumably #12999) made this pull request unmergeable. Please resolve the merge conflicts. |
Hey @J-ZhengLi, could you rebase on master? |
Hello @J-ZhengLi, Thanks again for working on this! I ran a poll of clippy contributors and the conclusion is that we'd like both I think it's okay if you want to do the implementation in two separate PRs, but please rename the lint you add here to match both cases. |
Awesome~ Thank you for keep tracking this (although I almost forgot about it lol). I'll get back to this in a few days~ @rustbot author |
closing this for now, if someone want to continue working on it, that will be wonderful~ (I personally don't have enough time and energy to finish this, but if someone want to pick it up, all that's left to do is adding a check for |
partially fix: #12895
cc: @pitaj
This only checks for
once_cell::sync::Lazy
, I want to split the implementations to at least 2 prs, aschecking. Also preventing this PR got too big (it already is...)lazy_static!
might needsEarlyPass
to be done properlychangelog: add new lint [
once_cell_lazy
] to detect usage of staticLazy
type.