Skip to content

Commit f52162f

Browse files
committed
Fix #[track_caller] location for function chains
1 parent f3fc94f commit f52162f

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/base.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -393,12 +393,18 @@ fn codegen_fn_content(fx: &mut FunctionCx<'_, '_, '_>) {
393393
func,
394394
args,
395395
destination,
396-
fn_span: _,
396+
fn_span,
397397
cleanup: _,
398398
from_hir_call: _,
399399
} => {
400400
fx.tcx.sess.time("codegen call", || {
401-
crate::abi::codegen_terminator_call(fx, source_info, func, args, *destination)
401+
crate::abi::codegen_terminator_call(
402+
fx,
403+
mir::SourceInfo { span: *fn_span, ..source_info },
404+
func,
405+
args,
406+
*destination,
407+
)
402408
});
403409
}
404410
TerminatorKind::InlineAsm {

0 commit comments

Comments
 (0)