diff options
| author | Weicao-CatilGrass <1992414357@qq.com> | 2026-05-13 07:34:45 +0800 |
|---|---|---|
| committer | Weicao-CatilGrass <1992414357@qq.com> | 2026-05-13 07:40:00 +0800 |
| commit | 2588933ebc500f439ebef075fef1064b0c5f0bcb (patch) | |
| tree | 595e55d7aa634bf7f730acaab7bcf243191c519a /mingling/src/example_docs.rs | |
| parent | 566b43cc15fc8a0bc7f962e05908486dbf53a7d0 (diff) | |
Add convenient `update_exit_code` and `exit_code` helper functions
Diffstat (limited to 'mingling/src/example_docs.rs')
| -rw-r--r-- | mingling/src/example_docs.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/mingling/src/example_docs.rs b/mingling/src/example_docs.rs index 09e84a8..1669344 100644 --- a/mingling/src/example_docs.rs +++ b/mingling/src/example_docs.rs @@ -371,9 +371,8 @@ pub mod example_dispatch_tree {} /// ```ignore /// use mingling::{ /// macros::{chain, dispatcher, gen_program, pack, r_println, renderer}, -/// res::ExitCode, +/// res::update_exit_code, /// setup::ExitCodeSetup, -/// this, /// }; /// /// fn main() { @@ -388,7 +387,7 @@ pub mod example_dispatch_tree {} /// /// #[chain] /// fn handle_error_entry(_prev: ErrorEntry) -> NextProcess { -/// this::<ThisProgram>().modify_res(|r: &mut ExitCode| r.exit_code = 1); +/// update_exit_code::<ThisProgram>(1); /// return ResultError::default(); /// } /// |
