Skip to content

Line-based breakpoints in inline functions don't show correct source #13442

Open
@jdm

Description

@jdm
#[inline(always)]
fn bar() -> int {
    5
}

fn main() {
    let _ = bar();
}
(gdb) break inline.rs:3
Breakpoint 1 at 0x404e80: file inline.rs, line 3.
(gdb) r
Starting program: /tmp/inline 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".

Breakpoint 1, inline::main () at inline.rs:6
6   fn main() {
(gdb) 

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-debuginfoArea: Debugging information in compiled programs (DWARF, PDB, etc.)C-bugCategory: This is a bug.P-mediumMedium priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions