diff --git a/Cargo.toml b/Cargo.toml index cf54d45a..120fbe19 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 e39e442e..dc5ff04f 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 c997e6ac..76ca0961 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"); } }