//! Synchronized one-time and lazy initialization primitives that use spin-locks
//! in case of concurrent accesses under contention.
use ;
use crate;
use crate;
use cratePOISON_PANIC_MSG;
use Spin;
////////////////////////////////////////////////////////////////////////////////////////////////////
// Lazy (type alias)
////////////////////////////////////////////////////////////////////////////////////////////////////
/// A type for lazy initialization of e.g. global static variables, which
/// provides the same functionality as the `lazy_static!` macro.
///
/// This type uses spin-locks if the initialization is contended and is thus
/// `#[no_std]` compatible.
///
/// For the API of this type alias, see the API of the generic
/// [`Lazy`](crate::doc::Lazy) type.
pub type Lazy<T, F = fn > = crate Lazy;
////////////////////////////////////////////////////////////////////////////////////////////////////
// OnceCell (type alias)
////////////////////////////////////////////////////////////////////////////////////////////////////
/// An interior mutability cell type which allows synchronized one-time
/// initialization and read-only access exclusively after initialization.
///
/// This type uses spin-locks if the initialization is contended and is thus
/// `#[no_std]` compatible.
///
/// For the API of this type alias, see the generic
/// [`OnceCell`](crate::doc::OnceCell) type.
pub type OnceCell<T> = crate OnceCell;
////////////////////////////////////////////////////////////////////////////////////////////////////
// Once (type alias)
////////////////////////////////////////////////////////////////////////////////////////////////////
/// A synchronization primitive which can be used to run a one-time global
/// initialization.
///
/// This type uses spin-locks if the initialization is contended and is thus
/// `#[no_std]` compatible.
///
/// For the API of this type alias, see the generic
/// [`OnceCell`](crate::doc::OnceCell) type.
/// This is a specialization with `T = ()`.
pub type Once = ;
////////////////////////////////////////////////////////////////////////////////////////////////////
// Spin
////////////////////////////////////////////////////////////////////////////////////////////////////
/********** impl Unblock **************************************************************************/
unsafe
/********** impl Block ****************************************************************************/
unsafe