# Type Alias TryLockResult

Source

    pub type TryLockResult<Guard> = Result<Guard, WouldBlock>;

🔬This is a nightly-only experimental API. (`sync_nonpoison` #134645)
Expand description

A type alias for the result of a nonblocking locking method.

## Aliased Type§

    pub enum TryLockResult<Guard> {
        Ok(Guard),
        Err(WouldBlock),
    }

## Variants§

§

### Ok(Guard)

🔬This is a nightly-only experimental API. (`sync_nonpoison` #134645)

Contains the success value

§

### Err(WouldBlock)

🔬This is a nightly-only experimental API. (`sync_nonpoison` #134645)

Contains the error value