1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
//! What:
//! Standalone process ownership of panic output and final exit handling.
//! Why:
//! A caught matcher panic must not leak scanned bytes through Rust's default panic hook.
//!
//! In TS you'd write (pseudocode):
//! ```ts
//! // Configure process output once, then guard the named startup operation.
//! ```
/// Import the existing application error type.
use Result;
/// Imports the process exit status returned once the guarded operation settles.
use ExitCode;
/// What:
/// Omit default panic payload output;
/// the operation's catch boundary supplies the redacted diagnostic.
/// Why:
/// Payloads,
/// thread names and caller locations are not assumed safe to print.
/// This callback alone does not catch an unwind and must be installed only by the process owner.
///
/// In TS you'd write (pseudocode):
/// ```ts
/// function omitPanicPayload(_information): void {}
/// ```
pub
/// Run one named operation,
/// preserving ordinary CLI errors and redacting unexpected panic payloads.
pub
/// Process-isolated controls avoid swapping hooks around concurrent tests or scan calls.