Skip to content

#[no_mangle] is silently ignored on generic fns #15844

Closed
@rpjohnst

Description

@rpjohnst

With a definition like this:

#[no_mangle]
fn foo<T>() { /* ... */ }

the compiler does not and cannot un-mangle foo, but it does not give any indication of this. It should probably give an unused_attribute warning.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsArea: Messages for errors, warnings, and lints

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions