mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-22 20:53:37 +00:00
Add new regression test for needless_pass_by_ref_mut
This commit is contained in:
parent
1d01f1bac1
commit
7e46217362
@ -221,6 +221,16 @@ async fn inner_async3(x: &mut i32, y: &mut u32) {
|
||||
.await;
|
||||
}
|
||||
|
||||
// Should not warn.
|
||||
async fn async_vec(b: &mut Vec<bool>) {
|
||||
b.append(&mut vec![]);
|
||||
}
|
||||
|
||||
// Should not warn.
|
||||
async fn async_vec2(b: &mut Vec<bool>) {
|
||||
b.push(true);
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let mut u = 0;
|
||||
let mut v = vec![0];
|
||||
|
Loading…
Reference in New Issue
Block a user