File tree Expand file tree Collapse file tree 1 file changed +1
-9
lines changed Expand file tree Collapse file tree 1 file changed +1
-9
lines changed Original file line number Diff line number Diff line change @@ -68,15 +68,7 @@ impl DebugContext {
6868 // In order to have a good line stepping behavior in debugger, we overwrite debug
6969 // locations of macro expansions with that of the outermost expansion site (when the macro is
7070 // annotated with `#[collapse_debuginfo]` or when `-Zdebug-macros` is provided).
71- let span = if tcx. should_collapse_debuginfo ( span) {
72- span
73- } else {
74- // Walk up the macro expansion chain until we reach a non-expanded span.
75- // We also stop at the function body level because no line stepping can occur
76- // at the level above that.
77- rustc_span:: hygiene:: walk_chain ( span, function_span. ctxt ( ) )
78- } ;
79-
71+ let span = tcx. collapsed_debuginfo ( span, function_span) ;
8072 match tcx. sess . source_map ( ) . lookup_line ( span. lo ( ) ) {
8173 Ok ( SourceFileAndLine { sf : file, line } ) => {
8274 let line_pos = file. lines ( ) [ line] ;
You can’t perform that action at this time.
0 commit comments