Open
Description
I can't find any documentation about double panic behavior (other than https://doc.rust-lang.org/std/ops/trait.Drop.html#panics, which currently just says "will likely abort the program"). There are some subtleties about this, because some handlers will cause a hang (see rust-lang/rust#97146).
I'm not sure exactly where or how to document this. Some thoughts:
- Would be good to add to the new panic chapter in panic runtime and C-unwind documentation #1226
- Might be good to include a note for
panic_handler
attribute - See also Document guarantees around drop and panicing #348 which is essentially the same thing. It might be good to include a note in https://doc.rust-lang.org/nightly/reference/destructors.html for that one.
Metadata
Metadata
Assignees
Labels
Type
Projects
Milestone
Relationships
Development
No branches or pull requests
Activity
chorman0773 commentedon Jan 13, 2025
Note that the behaviour of the default (in rustc libstd) panic handler is interesting here, and I don't know how much of that is stable or implementation detail: