-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Upstream stdx changes #19512
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
Upstream stdx changes #19512
Conversation
d6834ba
to
230ea7e
Compare
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.
Why all the random inlines? And most of the must use also seems unnecessary to me (aside from the constructors/builders).
I just followed a lint to add the inlines and must_use. must_use is recommended whenever the function doesn't appear to mutate its arguments, so it doesn't make sense to call the function if you don't need the resulting value. |
I find putting those on a bunch of functions blindly to be more noise than helpful. We don't run clippy with all pedantic lints precisely because a lot of those lints are subjectively questionable. As for inline specifically, none of that code is perf critical so we can just rely on the compiler doing the right thing (what it considers right). In fact, a lint telling you about when to use inline makes no sense to me. If the lint knows, the compiler should know either way. So I'd at least like to see the |
230ea7e
to
c235690
Compare
Let me know if there are any other changes you want me to undo. |
b44c5e7
to
9967d8b
Compare
9967d8b
to
428ee50
Compare
Thanks! |
I have some changes on my version of stdx that I figured I might as well PR back to r-a.
Let me know if there are things that you want me to undo.
Almost all of the changes come from following clippy lints which are not currently enabled in this workspace.