Skip to content

Add extern "abi" fn type to represent C pointers #3321

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
nikomatsakis opened this issue Aug 31, 2012 · 3 comments
Closed

Add extern "abi" fn type to represent C pointers #3321

nikomatsakis opened this issue Aug 31, 2012 · 3 comments
Labels
A-type-system Area: Type system C-enhancement Category: An issue proposing an enhancement or a PR with one.

Comments

@nikomatsakis
Copy link
Contributor

Per the recent weekly meeting, we should add a type to represent C style function pointers. This type should carry an ABI. This will be the type of extern functions from C code and we will no longer generate wrappers. We will allow this type to be coerced into a Rust closure, generating the stack-switching code. Finally, top-level Rust fn items will be usable as this type, in which case we will generate the thunk to do the stack-switch in the reverse direction.

@pnkfelix
Copy link
Member

This still needs to be implemented, but its not a blocker for 0.6

@alexcrichton
Copy link
Member

Nominating for the feature complete milestone

@nikomatsakis
Copy link
Contributor Author

Already implemented. I am working on a patch for the last piece, which is #3678.

RalfJung pushed a commit to RalfJung/rust that referenced this issue Mar 3, 2024
more dealing with macOS CI runners being slow

500ms seems to still sometimes not enough... so let's double it...
jaisnan pushed a commit to jaisnan/rust-dev that referenced this issue Jul 29, 2024
actions/checkout@v3 is causing trouble in the `BuildBundle-Linux`
workflow as described in rust-lang#3321 .

This PR sets `ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true` to continue
using `node16` so we don't find issues with `node20` dependencies in
`ubuntu-18.04` jobs. This is the option recommended in this GitHub post:
https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/

Resolves rust-lang#3321
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
A-type-system Area: Type system C-enhancement Category: An issue proposing an enhancement or a PR with one.
Projects
None yet
Development

No branches or pull requests

3 participants