1
Fork 0

Add std:🧵:available_concurrency

This commit is contained in:
Yoshua Wuyts 2020-07-18 17:11:46 +02:00
parent a8d6da3f57
commit 3717646366
4 changed files with 166 additions and 101 deletions

View file

@ -175,9 +175,15 @@ use crate::time::Duration;
#[macro_use]
mod local;
#[unstable(feature = "available_concurrency", issue = "74479")]
mod available_concurrency;
#[stable(feature = "rust1", since = "1.0.0")]
pub use self::local::{AccessError, LocalKey};
#[unstable(feature = "available_concurrency", issue = "74479")]
pub use available_concurrency::available_concurrency;
// The types used by the thread_local! macro to access TLS keys. Note that there
// are two types, the "OS" type and the "fast" type. The OS thread local key
// type is accessed via platform-specific API calls and is slow, while the fast