thread tighter span for closures around

Track the span corresponding to the `|...|` part of the closure.
This commit is contained in:
Niko Matsakis 2016-04-20 14:44:07 -04:00 committed by Manish Goregaokar
parent 23ccaddaa7
commit ecd10f04ce
29 changed files with 87 additions and 53 deletions

View file

@ -1258,7 +1258,7 @@ impl<'v, 'l, 'tcx: 'l, 'll, D: Dump +'ll> Visitor<'v> for DumpVisitor<'l, 'tcx,
ty),
}
}
ast::ExprKind::Closure(_, ref decl, ref body) => {
ast::ExprKind::Closure(_, ref decl, ref body, _fn_decl_span) => {
let mut id = String::from("$");
id.push_str(&ex.id.to_string());
self.process_formals(&decl.inputs, &id);