@@ -18,7 +18,7 @@ use rustc::hir::pat_util::pat_is_binding;
1818use std:: ops:: { Index , IndexMut } ;
1919use syntax:: ast;
2020use syntax:: codemap:: Span ;
21- use syntax:: parse:: token;
21+ use syntax:: parse:: token:: keywords ;
2222
2323pub struct Builder < ' a , ' tcx : ' a > {
2424 hir : Cx < ' a , ' tcx > ,
@@ -238,7 +238,7 @@ pub fn construct<'a,'tcx>(hir: Cx<'a,'tcx>,
238238 ty:: UpvarCapture :: ByRef ( ..) => true
239239 } ) ;
240240 let mut decl = UpvarDecl {
241- debug_name : token :: special_idents :: invalid . name ,
241+ debug_name : keywords :: Invalid . name ( ) ,
242242 by_ref : by_ref
243243 } ;
244244 if let Some ( hir:: map:: NodeLocal ( pat) ) = tcx. map . find ( fv. def . var_id ( ) ) {
@@ -296,7 +296,7 @@ impl<'a,'tcx> Builder<'a,'tcx> {
296296 self . schedule_drop ( pattern. as_ref ( ) . map_or ( ast_block. span , |pat| pat. span ) ,
297297 argument_extent, & lvalue, ty) ;
298298
299- let mut name = token :: special_idents :: invalid . name ;
299+ let mut name = keywords :: Invalid . name ( ) ;
300300 if let Some ( pat) = pattern {
301301 if let hir:: PatKind :: Ident ( _, ref ident, _) = pat. node {
302302 if pat_is_binding ( & self . hir . tcx ( ) . def_map . borrow ( ) , pat) {
0 commit comments