Fix ICE in ptr_arg

This commit is contained in:
Jason Newcomb 2022-02-01 15:05:20 -05:00
parent 7bb69c0ae0
commit e4f45c22e2
2 changed files with 4 additions and 1 deletions

View File

@ -649,7 +649,7 @@ fn check_ptr_arg_usage<'tcx>(cx: &LateContext<'tcx>, body: &'tcx Body<'_>, args:
},
_ => {
skip_count += 1;
results[arg.idx].skip = true;
results[i].skip = true;
None
},
}

View File

@ -0,0 +1,3 @@
fn f(x: u32, mut arg: &String) {}
fn main() {}