Skip to content

Explicitly namespace OS-specific definitions #18

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
mzabaluev opened this issue Sep 28, 2015 · 1 comment
Closed

Explicitly namespace OS-specific definitions #18

mzabaluev opened this issue Sep 28, 2015 · 1 comment

Comments

@mzabaluev
Copy link

There are reexports at the top level that are only available in Unix or Windows:

#[cfg(unix)] pub use consts::os::sysconf::*;

#[cfg(unix)] pub use funcs::posix88::mman::*;
#[cfg(unix)] pub use funcs::posix88::dirent::*;
#[cfg(unix)] pub use funcs::posix88::net::*;
#[cfg(unix)] pub use funcs::posix01::stat_::*;
#[cfg(unix)] pub use funcs::posix01::unistd::*;
#[cfg(unix)] pub use funcs::posix01::resource::*;


#[cfg(windows)] pub use funcs::extra::kernel32::*;
#[cfg(windows)] pub use funcs::extra::winsock::*;
#[cfg(windows)] pub use funcs::extra::msvcrt::*;

For clarity, and following the convention in std, these are better exported for public use in explicitly OS-specific modules os::unix and os::windows, and the top-level reexports deprecated.

@alexcrichton
Copy link
Member

Thanks for the report! This repo is actually currently slated for a revamp, as detailed in an RFC: rust-lang/rfcs#1291. The intention is to slate this library as platform-specific by default rather than platform-agnostic by default, but comments on the RFC are always welcome!

dlrobertson pushed a commit to dlrobertson/libc that referenced this issue Oct 31, 2017
bors pushed a commit that referenced this issue Oct 10, 2019
Sync to rust-lang/libc master
danielverkamp pushed a commit to danielverkamp/libc that referenced this issue Apr 28, 2020
Implementing `_mm_shuffle_epi8`.
lvllvl added a commit to lvllvl/libc that referenced this issue Jan 7, 2025
# This is the 1st commit message:

chore: add labels to FIXMEs

# This is the commit message rust-lang#2:

change label for .field FIXMEs
# This is the commit message rust-lang#3:

add fixme csv

# This is the commit message rust-lang#4:

Update fixmes.csv
# This is the commit message rust-lang#5:

Update fixmes.csv
# This is the commit message rust-lang#6:

Update fixmes.csv
# This is the commit message rust-lang#7:

Update fixmes.csv
# This is the commit message rust-lang#8:

Update fixmes.csv
# This is the commit message rust-lang#9:

Update fixmes.csv
# This is the commit message rust-lang#10:

Update fixmes.csv
# This is the commit message rust-lang#11:

Update fixmes.csv
# This is the commit message rust-lang#12:

Update fixmes.csv
# This is the commit message rust-lang#13:

Update fixmes.csv
# This is the commit message rust-lang#14:

Update fixmes.csv
# This is the commit message rust-lang#15:

Update fixmes.csv
# This is the commit message rust-lang#16:

Update fixmes.csv
# This is the commit message rust-lang#17:

Update fixmes.csv
# This is the commit message rust-lang#18:

updates to csv

# This is the commit message rust-lang#19:

Update fixmes.csv
# This is the commit message rust-lang#20:

Update fixmes.csv
# This is the commit message rust-lang#21:

Update fixmes.csv
# This is the commit message rust-lang#22:

Update fixmes.csv remove hurd"
# This is the commit message rust-lang#23:

Update fixmes.csv remove "'s
tgross35 pushed a commit to tgross35/rust-libc that referenced this issue Feb 22, 2025
Add support to emscripten targets
tgross35 pushed a commit to tgross35/rust-libc that referenced this issue Feb 22, 2025
tgross35 pushed a commit to tgross35/rust-libc that referenced this issue Apr 2, 2025
Add support to emscripten targets
tgross35 pushed a commit to tgross35/rust-libc that referenced this issue Apr 2, 2025
tgross35 pushed a commit to tgross35/rust-libc that referenced this issue Apr 2, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants