new lint: unnecessary_reserve - #14114
wowinter13 wants to merge 7 commits into
Conversation
unnecessary_reserve
|
@samueltardieu Samuel, really appreciate your review and points! |
samueltardieu
left a comment
There was a problem hiding this comment.
Could you include a test (maybe I've missed it) where extend() happens before reserve(), to make sure the lint doesn't trigger?
|
|
||
| // do not lint | ||
| vec.reserve(1); | ||
| vec.extend([1]); |
There was a problem hiding this comment.
Btw, error markers are now required in order for tests to pass. If you rebase over master, you will see examples in all the UI test files.
|
Also, is there any reason why this lint is not under the |
0bf67e5 to
37dfd0a
Compare
|
☔ The latest upstream changes (possibly d28d234) made this pull request unmergeable. Please resolve the merge conflicts. |
|
r? samueltardieu @wowinter13 do you plan to continue working on this? |
|
Closing since there was no response. @wowinter13 if you wish to return to working on this feel free to open a new PR. |
View all comments
resurrection of #10157
fixes #8982
changelog: [
unnecessary_reserve]: add new lint unnecessary_reserve