-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Split libc into types and impl crates #881
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
Comments
There has been discussion about exposing a It's a bit tricky because |
As Rust as a language is somewhat defined in C terms (so inherently relies on it), maybe multiple low-level primitive C types should be in If |
Because |
FYI |
C libraries (including system ones like glibc or musl) change, but C fundamentals stay put.
I expect many FFI bindings may rely only on fundamental language-provided types like
size_t
andc_void
, not on specific library-provided ones likesockaddr
orFILE
.To bring more stability to such use case, libc may be split into something like
libc-pure
with only type-level things that are expected to change when C as a language changes andlibc-sys
with everything else.libc
itself is just a bunch of re-exports.Exact splitting line and naming details is left to further discussion. A simple no-brainer constraint maybe that
unix:notbsd:fexecve
andc_int
should appear on opposite sides of the barricades.The text was updated successfully, but these errors were encountered: