Skip to content

Commit

Permalink
Clarify safety of PanicInfo::can_unwind
Browse files Browse the repository at this point in the history
  • Loading branch information
Amanieu committed Jan 30, 2022
1 parent c4f2d21 commit f738669
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions library/core/src/panic/panic_info.rs
Expand Up @@ -136,6 +136,10 @@ impl<'a> PanicInfo<'a> {
/// This is true for most kinds of panics with the exception of panics
/// caused by trying to unwind out of a `Drop` implementation or a function
/// whose ABI does not support unwinding.
///
/// It is safe for a panic handler to unwind even when this function returns
/// true, however this will simply cause the panic handler to be called
/// again.
#[must_use]
#[unstable(feature = "panic_can_unwind", issue = "92988")]
pub fn can_unwind(&self) -> bool {
Expand Down

0 comments on commit f738669

Please sign in to comment.