diff --git a/Cargo.toml b/Cargo.toml index cf54d45a6e5a0b3bb870994d6ce453e17456a201..120fbe19c662de2248790f546c36bec3ba61bdcd 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -26,9 +26,8 @@ rustc-std-workspace-core = { version = "1.0.0", optional = true } default = ["std"] std = [] align = [] -rustc-dep-of-std = ['align', 'rustc-std-workspace-core', 'unstable'] +rustc-dep-of-std = ['align', 'rustc-std-workspace-core'] extra_traits = [] -unstable = [] # use_std is deprecated, use `std` instead use_std = [ 'std' ] diff --git a/README.md b/README.md index e39e442e7af7fb294b1e8d1b4b5757e7f71ec4c8..dc5ff04fccff7f987d0adb19ab19d1ce17c98a92 100644 --- a/README.md +++ b/README.md @@ -35,11 +35,6 @@ libc = "0.2" * `extra_traits`: all `struct`s implemented in `libc` are `Copy` and `Clone`. This feature derives `Debug`, `Eq`, `Hash`, and `PartialEq`. -* `unstable`: This feature enables `libc` bindings that are only possible with - unstable Rust features. Right now, this just for - [`extern` `#[thread_local]` statics](https://github.com/rust-lang/rust/issues/29594) - on certain platforms. Requires nightly. - * **deprecated**: `use_std` is deprecated, and is equivalent to `std`. ## Rust version support diff --git a/build.rs b/build.rs index c997e6acfd3e7180d75b68f68dc485199bf5b04e..76ca0961e4782594d274b56224ecabb4cfbe926d 100644 --- a/build.rs +++ b/build.rs @@ -7,7 +7,6 @@ fn main() { rustc_minor_version().expect("Failed to get rustc version"); let rustc_dep_of_std = env::var("CARGO_FEATURE_RUSTC_DEP_OF_STD").is_ok(); let align_cargo_feature = env::var("CARGO_FEATURE_ALIGN").is_ok(); - let unstable_cargo_feature = env::var("CARGO_FEATURE_UNSTABLE").is_ok(); if env::var("CARGO_FEATURE_USE_STD").is_ok() { println!( @@ -55,7 +54,7 @@ fn main() { } // #[thread_local] is currently unstable - if unstable_cargo_feature || rustc_dep_of_std { + if rustc_dep_of_std { println!("cargo:rustc-cfg=libc_thread_local"); } }