Skip to content

Generic return values cause an ICE in type_metadata #8443

Closed
@jdm

Description

@jdm
fn foo<R>(r: R) -> R {
    r
}

pub fn main() {
    foo(0);
}

yields error: internal compiler error: debuginfo: unexpected type in type_metadata.

I presume this is a ty_infer, so I'm surprised we're seeing this in the debuginfo module while in the trans pass.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-debuginfoArea: Debugging information in compiled programs (DWARF, PDB, etc.)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions