We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent abf5592 commit 022bae8Copy full SHA for 022bae8
src/libstd/process.rs
@@ -1056,6 +1056,19 @@ pub fn exit(code: i32) -> ! {
1056
/// will be run. If a clean shutdown is needed it is recommended to only call
1057
/// this function at a known point where there are no more destructors left
1058
/// to run.
1059
+///
1060
+/// # Examples
1061
+/// ```
1062
+/// use std::process;
1063
1064
+/// fn main() {
1065
+/// println!("aborting");
1066
1067
+/// process::abort();
1068
1069
+/// // execution never gets here
1070
+/// }
1071
1072
#[stable(feature = "process_abort", since = "1.17.0")]
1073
pub fn abort() -> ! {
1074
unsafe { ::sys::abort_internal() };
0 commit comments