Skip to content

Commit

Permalink
Mention RefCell::take can panic in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ThinkChaos committed May 3, 2020
1 parent 4ea83bf commit 4a79424
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/libcore/cell.rs
Expand Up @@ -1026,6 +1026,10 @@ impl<T: ?Sized> RefCell<T> {
impl<T: Default> RefCell<T> {
/// Takes the wrapped value, leaving `Default::default()` in its place.
///
/// # Panics
///
/// Panics if the value is currently borrowed.
///
/// # Examples
///
/// ```
Expand Down

0 comments on commit 4a79424

Please sign in to comment.