std::terminate_handler(3)
π NAME π
okay bestie, welcome to the std::terminate_handler page from the C++ Standard Libary manual π
this one is literally about the function-pointer type that decides what happens when termination goes down.
β¨ Synopsis β¨
Defined in header <exception>
typedef void (*terminate_handler)();
std::terminate_handler is the function pointer type (pointer to function that takes no arguments and returns void), which is installed and queried by the functions std::set_terminate and std::get_terminate and called by std::terminate. no cap, that's the whole vibe π«Ά
A std::terminate_handler shall terminate execution of the program without returning to the caller, otherwise the behavior is undefined. periodt β it is not supposed to come back and say "hey bestie, I'm done" π that's undefined behavior territory, fr fr π
The C++ implementation provides a default std::terminate_handler function, which calls std::abort(). If the null pointer value is installed (by means of std::set_terminate), the implementation may restore the default handler instead.
π See also π
terminateβ function called when exception handling fails (function)set_terminateβ changes the function to be called bystd::terminate(function)get_terminateβ obtains the currentterminate_handler(C++11) (function)
mwah π β source/version/date vibes: http://cppreference.com, 2024.06.10, page std::terminate_handler(3). that's the whole page, bestie π«Ά
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms