pub(crate) fn push<S: Into<T>>(&self, string: S) -> &T::Target {
        // SAFETY:
        //   * Aliasing: We retrieve a mutable reference to the last slot (via
        //     `push()`) and then return said reference as immutable; these
        //     occur in serial, so they don't alias. This method accesses a
        //     unique slot each call: the last slot, subsequently replaced by
        //     `push()` each next call. No other method accesses the internal
        //     buffer directly. Thus, the outstanding reference to the last slot
        //     is never accessed again mutably, preserving aliasing guarantees.
        //   * Liveness: The returned reference is to a `String`; we must ensure
        //     that the `String` is never dropped while `self` lives. This is
        //     guaranteed by returning a reference with the same lifetime as
        //     `self`, so `self` can't be dropped while the string is live, and
        //     by never removing elements from the internal `Vec` thus not
        //     dropping `String` itself: `push()` is the only mutating operation
        //     called on `Vec`, which preserves all previous elements; the
        //     stability of `String` itself means that the returned address
        //     remains valid even after internal realloc of `Vec`.
        //   * Thread-Safety: Parallel calls to `push_one` without exclusion
        //     would result in a race to `vec.push()`; `RawMutex` ensures that
        //     this doesn't occur.
        unsafe {
            self.mutex.lock();
            let vec: &mut Vec<T> = &mut *self.stack.get();
            vec.push(string.into());
            let last = vec.last().expect("push() => non-empty");
            self.mutex.unlock();
            last
        }
    }
/// Pushes the string `S` onto the stack. Returns a reference of the string
/// in the stack.
Pushes the string `S` onto the stack. Returns a reference of the string
in the stack.
Pushes the string ` S ` onto the stack . Returns a reference of the string in the stack .
pub(crate) fn push<S: Into<T>>(&self, string: S) -> &T::Target {
        // SAFETY:
        //   * Aliasing: We retrieve a mutable reference to the last slot (via
        //     `push()`) and then return said reference as immutable; these
        //     occur in serial, so they don't alias. This method accesses a
        //     unique slot each call: the last slot, subsequently replaced by
        //     `push()` each next call. No other method accesses the internal
        //     buffer directly. Thus, the outstanding reference to the last slot
        //     is never accessed again mutably, preserving aliasing guarantees.
        //   * Liveness: The returned reference is to a `String`; we must ensure
        //     that the `String` is never dropped while `self` lives. This is
        //     guaranteed by returning a reference with the same lifetime as
        //     `self`, so `self` can't be dropped while the string is live, and
        //     by never removing elements from the internal `Vec` thus not
        //     dropping `String` itself: `push()` is the only mutating operation
        //     called on `Vec`, which preserves all previous elements; the
        //     stability of `String` itself means that the returned address
        //     remains valid even after internal realloc of `Vec`.
        //   * Thread-Safety: Parallel calls to `push_one` without exclusion
        //     would result in a race to `vec.push()`; `RawMutex` ensures that
        //     this doesn't occur.
        unsafe {
            self.mutex.lock();
            let vec: &mut Vec<T> = &mut *self.stack.get();
            vec.push(string.into());
            let last = vec.last().expect("push() => non-empty");
            self.mutex.unlock();
            last
        }
    }
pub ( crate ) fn push < S : Into < T > > ( & self , string : S ) -> & T :: Target { // SAFETY: //   * Aliasing: We retrieve a mutable reference to the last slot (via //     `push()`) and then return said reference as immutable; these //     occur in serial, so they don't alias. This method accesses a //     unique slot each call: the last slot, subsequently replaced by //     `push()` each next call. No other method accesses the internal //     buffer directly. Thus, the outstanding reference to the last slot //     is never accessed again mutably, preserving aliasing guarantees. //   * Liveness: The returned reference is to a `String`; we must ensure //     that the `String` is never dropped while `self` lives. This is //     guaranteed by returning a reference with the same lifetime as //     `self`, so `self` can't be dropped while the string is live, and //     by never removing elements from the internal `Vec` thus not //     dropping `String` itself: `push()` is the only mutating operation //     called on `Vec`, which preserves all previous elements; the //     stability of `String` itself means that the returned address //     remains valid even after internal realloc of `Vec`. //   * Thread-Safety: Parallel calls to `push_one` without exclusion //     would result in a race to `vec.push()`; `RawMutex` ensures that //     this doesn't occur. unsafe { self . mutex . lock ( ) ; let vec : & mut Vec < T > = & mut * self . stack . get ( ) ; vec . push ( string . into ( ) ) ; let last = vec . last ( ) . expect ( " " ) ; self . mutex . unlock ( ) ; last } }
Pushes the string `S` onto the stack.
Pushes the string ` S ` onto the stack .
&self
string
S
&self
string
S