bors f7189846be Auto merge of #8953 - DevAccentor:slow_vector_initialization, r=Manishearth
add vec.capacity() to [`slow_vec_initialization`] detection

fix #8800

for example
```rust
let mut vec1 = Vec::with_capacity(len);
vec1.resize(vec1.capacity(), 0);

let mut vec2 = Vec::with_capacity(len);
vec2.extend(repeat(0).take(vec2.capacity()));
```
will trigger the lint

---

changelog: add `vec.capacity()` to [`slow_vec_initialization`] detection
2022-06-23 22:29:52 +00:00
..
2022-06-20 11:05:40 +09:00
2022-02-24 22:55:40 +03:00
2022-02-24 22:55:40 +03:00
2022-06-20 12:03:27 +00:00
2022-03-30 20:13:16 +02:00
2022-06-14 23:30:43 +09:00
2022-06-14 23:30:43 +09:00
2022-04-17 11:03:34 +02:00