Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Move std::libc to standalone libc, and rename all c_type to c::type #12514

Closed
liigo opened this issue Feb 24, 2014 · 3 comments
Closed

Move std::libc to standalone libc, and rename all c_type to c::type #12514

liigo opened this issue Feb 24, 2014 · 3 comments

Comments

@liigo
Copy link
Contributor

liigo commented Feb 24, 2014

I would like to do this work later, if no objection.

@huonw
Copy link
Member

huonw commented Feb 24, 2014

cc #12469 for some similar discussion.

However, unfortunately, if we move c_vec and c_str to cffi (or whatever), then either std depends on that (and so cffi can't even use Option or any ~/proc/etc. allocations), or cffi depends on std and so std cannot use anything from cffi (which is essentially infeasible, since std interacts with the OS).

@thestinger
Copy link
Contributor

c_vec and c_str aren't provided by the C standard library so they wouldn't belong there. This should be done with enough foresight to provide backwards compatibility when libclang replaces these hard-wired ABIs at a compiler level.

@emberian
Copy link
Member

libc is its own crate now.

bors added a commit to rust-lang-ci/rust that referenced this issue Jul 25, 2022
flip1995 pushed a commit to flip1995/rust that referenced this issue May 2, 2024
fix `for x in y unsafe { }`

fixes rust-lang#12514

----

changelog: [`needless_for_each`]: unsafe block in for loop body suggestion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants