@@ -102,6 +102,7 @@ pub enum CandidateSource {
102
102
103
103
impl < ' a , ' tcx > FnCtxt < ' a , ' tcx > {
104
104
/// Determines whether the type `self_ty` supports a method name `method_name` or not.
105
+ #[ instrument( level = "debug" , skip( self ) ) ]
105
106
pub fn method_exists (
106
107
& self ,
107
108
method_name : Ident ,
@@ -129,6 +130,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
129
130
}
130
131
131
132
/// Adds a suggestion to call the given method to the provided diagnostic.
133
+ #[ instrument( level = "debug" , skip( self , err, call_expr) ) ]
132
134
crate fn suggest_method_call (
133
135
& self ,
134
136
err : & mut DiagnosticBuilder < ' a > ,
@@ -177,6 +179,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
177
179
/// * `span`: the span for the method call
178
180
/// * `call_expr`: the complete method call: (`foo.bar::<T1,...Tn>(...)`)
179
181
/// * `self_expr`: the self expression (`foo`)
182
+ #[ instrument( level = "debug" , skip( self , call_expr, self_expr) ) ]
180
183
pub fn lookup_method (
181
184
& self ,
182
185
self_ty : Ty < ' tcx > ,
@@ -204,6 +207,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
204
207
205
208
let result =
206
209
self . confirm_method ( span, self_expr, call_expr, self_ty, pick. clone ( ) , segment) ;
210
+ debug ! ( "result = {:?}" , result) ;
207
211
208
212
if let Some ( span) = result. illegal_sized_bound {
209
213
let mut needs_mut = false ;
@@ -256,6 +260,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
256
260
Ok ( result. callee )
257
261
}
258
262
263
+ #[ instrument( level = "debug" , skip( self , call_expr) ) ]
259
264
pub fn lookup_probe (
260
265
& self ,
261
266
span : Span ,
@@ -286,6 +291,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
286
291
// FIXME(#18741): it seems likely that we can consolidate some of this
287
292
// code with the other method-lookup code. In particular, the second half
288
293
// of this method is basically the same as confirmation.
294
+ #[ instrument( level = "debug" , skip( self , span, opt_input_types) ) ]
289
295
pub fn lookup_method_in_trait (
290
296
& self ,
291
297
span : Span ,
@@ -409,6 +415,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
409
415
Some ( InferOk { obligations, value : callee } )
410
416
}
411
417
418
+ #[ instrument( level = "debug" , skip( self ) ) ]
412
419
pub fn resolve_ufcs (
413
420
& self ,
414
421
span : Span ,
0 commit comments