Skip to content

DWARF does not mention Self type #33175

@tromey

Description

@tromey

I wrote a simple test program using the Self type:

struct Something(i32);

impl Something {
    fn x(self: &Self) -> i32 { self.0 }
}

fn main() {
    let y = Something(32);
    let z = y.x();

    ()
}

When I examine the resulting DWARF, I don't see any mention of Self. I think it should be emitted as a typedef pointing to Something.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-debuginfoArea: Debugging information in compiled programs (DWARF, PDB, etc.)C-enhancementCategory: An issue proposing an enhancement or a PR with one.P-lowLow 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