]> git.lizzy.rs Git - rust.git/commitdiff
Updated RwLock Docs
authorNabeel Omer <nabeelkomer@gmail.com>
Thu, 13 Oct 2016 15:07:09 +0000 (20:37 +0530)
committerNabeel Omer <nabeelkomer@gmail.com>
Thu, 13 Oct 2016 15:07:09 +0000 (20:37 +0530)
src/libstd/sync/rwlock.rs

index 48ecae185f95c37e9e9a54a3e24c121587bb5fcc..c5a03f72e29020bb47e6e0188f807151d829dd13 100644 (file)
@@ -63,6 +63,9 @@
 ///     assert_eq!(*w, 6);
 /// } // write lock is dropped here
 /// ```
+/// # Panics
+///
+/// This function might panic when called if the lock is already held by the current thread.
 #[stable(feature = "rust1", since = "1.0.0")]
 pub struct RwLock<T: ?Sized> {
     inner: Box<sys::RWLock>,