Skip to content

Add a method to get the FnAbi of a function pointer #63

@celinval

Description

@celinval
Contributor

We have added a method to get the function ABI of an instance, however, that doesn't work for function pointers. We should consider adding a similar API to the query fn_abi_of_fn_ptr(/*..*/).

Activity

oli-obk

oli-obk commented on Feb 22, 2024

@oli-obk
Contributor

function pointer types have a fn sig field https://doc.rust-lang.org/nightly/nightly-rustc/stable_mir/ty/struct.FnSig.html that contains the ABI.

celinval

celinval commented on Feb 22, 2024

@celinval
ContributorAuthor

That just represents the ABI type not the argument's ABI though. I changed the title of this issue to avoid any confusion. Sorry about that!

changed the title [-]Add a method to get the ABI of a function pointer[/-] [+]Add a method to get the `FnAbi` of a function pointer[/+] on Feb 22, 2024
adwinwhite

adwinwhite commented on Jun 18, 2024

@adwinwhite

@rustbot claim

added a commit that references this issue on Jun 22, 2024
e843355
added a commit that references this issue on Jun 22, 2024
1f9793f
added a commit that references this issue on Jun 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Development

    Participants

    @oli-obk@celinval@adwinwhite

    Issue actions

      Add a method to get the `FnAbi` of a function pointer · Issue #63 · rust-lang/project-stable-mir