This commit is contained in:
Matthias Krüger 2018-12-08 01:56:03 +01:00 committed by Philipp Hansch
parent 26602ddff4
commit f13d23de41
No known key found for this signature in database
GPG key ID: B6FA06A6E0E2665B
46 changed files with 140 additions and 140 deletions

View file

@ -21,7 +21,7 @@ pub fn get_spans(
idx: usize,
replacements: &'static [(&'static str, &'static str)],
) -> Option<Vec<(Span, Cow<'static, str>)>> {
if let Some(body) = opt_body_id.map(|id| cx.tcx.hir.body(id)) {
if let Some(body) = opt_body_id.map(|id| cx.tcx.hir().body(id)) {
get_binding_name(&body.arguments[idx]).map_or_else(
|| Some(vec![]),
|name| extract_clone_suggestions(cx, name, replacements, body),