New lint: vec_init_then_push - #6538
Conversation
|
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @llogiq (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
|
I like this addition! Just a small nit: I'd make use of inference to keep the docs lean. Also I think the Changelog line in the PR description should be the last line. |
|
Thank you! @bors r+ |
|
📌 Commit 7b5f549 has been approved by |
|
☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test |
fixes: #1483
This will trigger on
new,default, andwith_capacitywhen the given capacity is less than or equal to the number of push calls. Is there anything else this should trigger on?changelog: Added lint:
vec_init_then_push