@@ -12,7 +12,7 @@ use rustc_ast::token;
1212use rustc_ast:: tokenstream:: TokenStream ;
1313use rustc_ast:: visit:: { self , AssocCtxt , Visitor } ;
1414use rustc_ast:: { AssocItemKind , AstLike , AstLikeWrapper , AttrStyle , ExprKind , ForeignItemKind } ;
15- use rustc_ast:: { Inline , ItemKind , MacArgs , MacStmtStyle , MetaItemKind , ModKind , ModSpans } ;
15+ use rustc_ast:: { Inline , ItemKind , MacArgs , MacStmtStyle , MetaItemKind , ModKind } ;
1616use rustc_ast:: { NestedMetaItem , NodeId , PatKind , StmtKind , TyKind } ;
1717use rustc_ast_pretty:: pprust;
1818use rustc_data_structures:: map_in_place:: MapInPlace ;
@@ -364,7 +364,7 @@ impl<'a, 'b> MacroExpander<'a, 'b> {
364364 }
365365
366366 pub fn expand_crate ( & mut self , krate : ast:: Crate ) -> ast:: Crate {
367- let file_path = match self . cx . source_map ( ) . span_to_filename ( krate. span ) {
367+ let file_path = match self . cx . source_map ( ) . span_to_filename ( krate. spans . inner_span ) {
368368 FileName :: Real ( name) => name
369369 . into_local_path ( )
370370 . expect ( "attempting to resolve a file path in an external file" ) ,
@@ -1091,7 +1091,7 @@ impl InvocationCollectorNode for P<ast::Item> {
10911091 ModKind :: Unloaded => {
10921092 // We have an outline `mod foo;` so we need to parse the file.
10931093 let old_attrs_len = attrs. len ( ) ;
1094- let ParsedExternalMod { items, inner_span , file_path, dir_path, dir_ownership } =
1094+ let ParsedExternalMod { items, spans , file_path, dir_path, dir_ownership } =
10951095 parse_external_mod (
10961096 & ecx. sess ,
10971097 ident,
@@ -1112,7 +1112,7 @@ impl InvocationCollectorNode for P<ast::Item> {
11121112 ) ;
11131113 }
11141114
1115- * mod_kind = ModKind :: Loaded ( items, Inline :: No , ModSpans { inner_span } ) ;
1115+ * mod_kind = ModKind :: Loaded ( items, Inline :: No , spans ) ;
11161116 node. attrs = attrs;
11171117 if node. attrs . len ( ) > old_attrs_len {
11181118 // If we loaded an out-of-line module and added some inner attributes,
0 commit comments