pub fn new(f: fn() -> T) -> Self {
        ThreadLocal {
            key: unsafe { oskey::create(Some(thread_local_drop::<T>)) },
            init: f,
        }
    }
/// Creates a new thread-local storage handle.
///
/// The provided function is used to initialize the value on the first use in
/// each thread.
///
/// ```rust
/// use os_thread_local::ThreadLocal;
///
/// let tls = ThreadLocal::new(|| 42);
/// ```
Creates a new thread-local storage handle.
The provided function is used to initialize the value on the first use in
each thread.




Creates a new thread - local storage handle . The provided function is used to initialize the value on the first use in each thread .
pub fn new(f: fn() -> T) -> Self {
        ThreadLocal {
            key: unsafe { oskey::create(Some(thread_local_drop::<T>)) },
            init: f,
        }
    }
pub fn new ( f : fn ( ) -> T ) -> Self { ThreadLocal { key : unsafe { oskey :: create ( Some ( thread_local_drop :: < T > ) ) } , init : f , } }
Creates a new thread-local storage handle.
Creates a new thread - local storage handle .
f
fn() -> T
f
fn() -> T