pub fn read(self) -> Result<RwLockReadGuard<'a, T>, Errno> {
        // Safety: A RwLockRef can only be obtained by calling
        // RwLock::initialize or -acquire. Therefore, we should
        // have a pointer to a valid rwlock.
        let success = Self::try_fastlock(|| unsafe {
            libc::pthread_rwlock_tryrdlock(self.0.lock_ptr()) == 0
        });
        if !success {
            unsafe {
                Errno::from(libc::pthread_rwlock_rdlock(self.0.lock_ptr()))?;
            }
        }
        Ok(RwLockReadGuard { lock: self })
    }
/// Locks this rwlock with shared read access, blocking the current
/// thread until it can be acquired.
///
/// Note that, according to the pthread_rwlock_rdlock manual page, this
/// does support recursive locking.
Locks this rwlock with shared read access, blocking the current
thread until it can be acquired.

Note that, according to the pthread_rwlock_rdlock manual page, this
does support recursive locking.
Locks this rwlock with shared read access blocking the current thread until it can be acquired . Note that according to the pthread_rwlock_rdlock manual page this does support recursive locking .
pub fn read(self) -> Result<RwLockReadGuard<'a, T>, Errno> {
        // Safety: A RwLockRef can only be obtained by calling
        // RwLock::initialize or -acquire. Therefore, we should
        // have a pointer to a valid rwlock.
        let success = Self::try_fastlock(|| unsafe {
            libc::pthread_rwlock_tryrdlock(self.0.lock_ptr()) == 0
        });
        if !success {
            unsafe {
                Errno::from(libc::pthread_rwlock_rdlock(self.0.lock_ptr()))?;
            }
        }
        Ok(RwLockReadGuard { lock: self })
    }
pub fn read ( self ) -> Result < RwLockReadGuard < ' a , T > , Errno > { // Safety: A RwLockRef can only be obtained by calling // RwLock::initialize or -acquire. Therefore, we should // have a pointer to a valid rwlock. let success = Self :: try_fastlock ( | | unsafe { libc :: pthread_rwlock_tryrdlock ( self . 0 . lock_ptr ( ) ) == 0 } ) ; if ! success { unsafe { Errno :: from ( libc :: pthread_rwlock_rdlock ( self . 0 . lock_ptr ( ) ) ) ? ; } } Ok ( RwLockReadGuard { lock : self } ) }
Locks this rwlock with shared read access, blocking the current
thread until it can be acquired.
Locks this rwlock with shared read access blocking the current thread until it can be acquired .
self
self