Stream: general

Topic: Should clippy lints be fixed in a separate PR?


Avi Dessauer (Oct 06 2019 at 02:30, on Zulip):

If I see clippy/rust-analyzer lints while working should I fix them in the PR I'm working on or a separate one?
In this case the lint is Shorthand struct initialization.

Josh Triplett (Oct 06 2019 at 02:37, on Zulip):

Depends. On code you've just modified or introduced? Or do the lints occur on the unmodified code?

Josh Triplett (Oct 06 2019 at 02:37, on Zulip):

If the former, fix them in the same commit so there's never a commit that produces the lints.

Josh Triplett (Oct 06 2019 at 02:38, on Zulip):

If the latter, separate PR.

Jake Goulding (Oct 07 2019 at 13:57, on Zulip):

While I personally prefer separate PR, I know that's not universally accepted. I'd put such fixes in a separate commit if nothing else.

Josh Triplett (Oct 07 2019 at 18:11, on Zulip):

Yes, definitely in a separate commit.

Last update: Nov 20 2019 at 12:00UTC