- }
-}
-
-///////////////////////////////////////////////////////////////////////////
-// ADJUST BORROW KIND
-
-struct AdjustBorrowKind<'a, 'gcx: 'a+'tcx, 'tcx: 'a> {
- fcx: &'a FnCtxt<'a, 'gcx, 'tcx>,
- temp_closure_kinds: NodeMap<(ty::ClosureKind, Option<(Span, ast::Name)>)>,
-}
-
-impl<'a, 'gcx, 'tcx> AdjustBorrowKind<'a, 'gcx, 'tcx> {
- fn new(fcx: &'a FnCtxt<'a, 'gcx, 'tcx>,
- temp_closure_kinds: NodeMap<(ty::ClosureKind, Option<(Span, ast::Name)>)>)
- -> AdjustBorrowKind<'a, 'gcx, 'tcx> {
- AdjustBorrowKind { fcx: fcx, temp_closure_kinds: temp_closure_kinds }
- }
-
- fn analyze_closure(&mut self,
- id: ast::NodeId,
- span: Span,
- body: &hir::Body) {
- /*!
- * Analysis starting point.
- */
-
- debug!("analyze_closure(id={:?}, body.id={:?})", id, body.id());