@@ -20,9 +20,9 @@ panic traverses Rust frames, live objects in those frames that [implement
20
20
recovery does occur (for instance at a thread boundary), the objects will have
21
21
been "cleaned up" just as if they had gone out of scope normally.
22
22
23
- > ** Note** : As long as this guarantee of resource-cleanup is preserved, "unwinding" may
24
- > be implemented without actually using the mechanism used by C++ for the
25
- > target platform.
23
+ > ** Note** : As long as this guarantee of resource-cleanup is preserved,
24
+ > "unwinding" may be implemented without actually using the mechanism used by
25
+ > C++ for the target platform.
26
26
27
27
> ** Note** : The Standard Library provides two mechanisms for recovering from a panic,
28
28
> [ ` catch_unwind ` ] [ fn-catch-unwind ] (which enables recovery within the
@@ -34,9 +34,11 @@ been "cleaned up" just as if they had gone out of scope normally.
34
34
The actual behavior and implementation of ` panic! ` is controlled by the _ panic
35
35
runtime_ .
36
36
37
- > ** Note** : The Rust standard library provides two panic runtimes: ` panic_unwind ` (the
38
- > default) and ` panic_abort ` , which immediately aborts the process (which is
39
- > non-recoverable).
37
+ > ** Note** : The Rust standard library provides two panic runtimes:
38
+ > ` panic_unwind ` (which unwinds the stack and is potentially recoverable) and
39
+ > ` panic_abort ` (which aborts the process and is non-recoverable). The default
40
+ > runtime depends on the target platform, but is generally ` panic_unwind ` on
41
+ > platforms with native support for C++ exceptions.
40
42
41
43
When compiling code that is guaranteed to be linked to a non-recoverable panic
42
44
runtime, the optimizer may assume that unwinding across Rust frames is
0 commit comments