@@ -148,7 +148,7 @@ impl HirFileId {
148
148
match self . 0 {
149
149
HirFileIdRepr :: FileId ( file_id) => file_id,
150
150
HirFileIdRepr :: MacroFile ( macro_file) => {
151
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
151
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
152
152
let file_id = match & loc. eager {
153
153
Some ( EagerCallInfo { included_file : Some ( file) , .. } ) => ( * file) . into ( ) ,
154
154
_ => loc. kind . file_id ( ) ,
@@ -162,7 +162,7 @@ impl HirFileId {
162
162
let mut level = 0 ;
163
163
let mut curr = self ;
164
164
while let HirFileIdRepr :: MacroFile ( macro_file) = curr. 0 {
165
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
165
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
166
166
167
167
level += 1 ;
168
168
curr = loc. kind . file_id ( ) ;
@@ -175,7 +175,7 @@ impl HirFileId {
175
175
match self . 0 {
176
176
HirFileIdRepr :: FileId ( _) => None ,
177
177
HirFileIdRepr :: MacroFile ( macro_file) => {
178
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
178
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
179
179
Some ( loc. kind . to_node ( db) )
180
180
}
181
181
}
@@ -186,7 +186,7 @@ impl HirFileId {
186
186
match self . 0 {
187
187
HirFileIdRepr :: FileId ( _) => None ,
188
188
HirFileIdRepr :: MacroFile ( macro_file) => {
189
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
189
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
190
190
191
191
let arg_tt = loc. kind . arg ( db) ?;
192
192
@@ -231,7 +231,7 @@ impl HirFileId {
231
231
match self . 0 {
232
232
HirFileIdRepr :: FileId ( _) => None ,
233
233
HirFileIdRepr :: MacroFile ( macro_file) => {
234
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
234
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
235
235
let item = match loc. def . kind {
236
236
MacroDefKind :: BuiltInDerive ( ..) => loc. kind . to_node ( db) ,
237
237
_ => return None ,
@@ -245,7 +245,7 @@ impl HirFileId {
245
245
match self . 0 {
246
246
HirFileIdRepr :: FileId ( _) => false ,
247
247
HirFileIdRepr :: MacroFile ( macro_file) => {
248
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
248
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
249
249
match loc. def . kind {
250
250
MacroDefKind :: ProcMacro ( _, ProcMacroKind :: CustomDerive , _) => true ,
251
251
_ => false ,
@@ -258,7 +258,7 @@ impl HirFileId {
258
258
pub fn is_include_macro ( & self , db : & dyn db:: AstDatabase ) -> bool {
259
259
match self . 0 {
260
260
HirFileIdRepr :: MacroFile ( macro_file) => {
261
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
261
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
262
262
matches ! ( loc. eager, Some ( EagerCallInfo { included_file: Some ( _) , .. } ) )
263
263
}
264
264
_ => false ,
@@ -269,7 +269,7 @@ impl HirFileId {
269
269
pub fn is_attr_macro ( & self , db : & dyn db:: AstDatabase ) -> bool {
270
270
match self . 0 {
271
271
HirFileIdRepr :: MacroFile ( macro_file) => {
272
- let loc: MacroCallLoc = db. lookup_intern_macro ( macro_file. macro_call_id ) ;
272
+ let loc: MacroCallLoc = db. lookup_intern_macro_call ( macro_file. macro_call_id ) ;
273
273
matches ! ( loc. kind, MacroCallKind :: Attr { .. } )
274
274
}
275
275
_ => false ,
@@ -288,7 +288,7 @@ impl MacroDefId {
288
288
krate : CrateId ,
289
289
kind : MacroCallKind ,
290
290
) -> MacroCallId {
291
- db. intern_macro ( MacroCallLoc { def : self , krate, eager : None , kind } )
291
+ db. intern_macro_call ( MacroCallLoc { def : self , krate, eager : None , kind } )
292
292
}
293
293
294
294
pub fn ast_id ( & self ) -> Either < AstId < ast:: Macro > , AstId < ast:: Fn > > {
@@ -402,7 +402,7 @@ impl ExpansionInfo {
402
402
HirFileIdRepr :: FileId ( _) => return None ,
403
403
HirFileIdRepr :: MacroFile ( macro_file) => macro_file. macro_call_id ,
404
404
} ;
405
- let loc = db. lookup_intern_macro ( call_id) ;
405
+ let loc = db. lookup_intern_macro_call ( call_id) ;
406
406
407
407
let token_range = token. value . text_range ( ) ;
408
408
match & loc. kind {
@@ -458,7 +458,7 @@ impl ExpansionInfo {
458
458
HirFileIdRepr :: FileId ( _) => return None ,
459
459
HirFileIdRepr :: MacroFile ( macro_file) => macro_file. macro_call_id ,
460
460
} ;
461
- let loc = db. lookup_intern_macro ( call_id) ;
461
+ let loc = db. lookup_intern_macro_call ( call_id) ;
462
462
463
463
let ( token_map, tt) = match & loc. kind {
464
464
MacroCallKind :: Attr { attr_args, .. } => match self . macro_arg_shift . unshift ( token_id) {
0 commit comments