Skip to content

Commit 6ad5764

Browse files
Kyle StrandBatmanAoD
authored andcommitted
edits to 'runtime'
1 parent c8f2839 commit 6ad5764

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

src/panic.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ been "cleaned up" just as if they had gone out of scope normally.
3030
> continue execution without recovering the panicked thread).
3131
3232
## Panic runtimes
33-
[top]: #panic-runtimes
3433

3534
The actual behavior and implementation of `panic!` is controlled by the _panic
3635
runtime_.
@@ -43,7 +42,10 @@ When compiling code that is guaranteed to be linked to a non-recoverable panic
4342
runtime, the optimizer may assume that unwinding across Rust frames is
4443
impossible, which can result in both code-size and runtime speed improvements.
4544

45+
See also ["The Rust runtime"][runtime].
46+
4647
[destructors]: destructors.md
4748
[fn-catch-unwind]: ../std/panic/fn.catch_unwind.html
4849
[macro-panic]: ../std/macro.panic.html
4950
[thread-join]: ../std/thread/struct.JoinHandle.html#method.join
51+
[runtime]: runtime.md

src/runtime.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,10 @@ fn panic(info: &PanicInfo) -> ! {
4747

4848
The standard library provides an implementation of `panic_handler` that
4949
defaults to unwinding the stack but that can be [changed to abort the
50-
process][abort]. The standard library's panic behavior can be modified at
51-
runtime with the [set_hook] function.
50+
process][abort]. See also ["Panic runtimes"][panic-runtimes].
51+
52+
The standard library's panic behavior can be modified at runtime with the
53+
[`set_hook` function][set_hook].
5254

5355
## The `global_allocator` attribute
5456

@@ -80,6 +82,7 @@ display a console window on startup. It will run detached from any existing cons
8082
[abort]: ../book/ch09-01-unrecoverable-errors-with-panic.html
8183
[attribute]: attributes.md
8284
[crate types]: linkage.md
85+
[panic-runtimes]: panic.md#panic-runtimes
8386
[set_hook]: ../std/panic/fn.set_hook.html
8487
[static item]: items/static-items.md
8588
[subsystem]: https://msdn.microsoft.com/en-us/library/fcc1zstk.aspx

0 commit comments

Comments
 (0)