std::nested...throw_nested(3)
π NAME π
okay so bestie, welcome to the std::nested_exception::rethrow_nested page from the C++ Standard Libary π
. The name line is literally std::nested_exception::rethrow_nested β std::nested_exception::rethrow_nested (yes, it said it twice, and honestly? iconic π). This function is the one that rethrows the stored exception, and if thereβs no stored exception itβs giving std::terminate energy π.
β¨ Synopsis β¨
[[noreturn]] void rethrow_nested() const; (since C++11)
so what does it actually do? It rethrows the stored exception π₯. If there is no stored exceptions (i.e. nested_ptr() returns a null pointer), then std::terminate is called. and thatβs the whole plot, bestie π.
This slayful signature has been around since C++11 π. The [[noreturn]] is literally right there in the signature, so donβt expect it to come back and say hi π«Ά.
β οΈ real talk: it rethrows the stored exception. But if there is no stored exceptions (i.e.nested_ptr()returns a null pointer), thenstd::terminateis called. not a vibe check you want to fail π.
π Parameters π
(none) β zero, nada, no arguments, bestie π.
π¦ Return value π¦
(none) β none at all, because [[noreturn]] said what it said π
.
source/version check bestie: http://cppreference.com, date 2024.06.10, page std::nested...throw_nested(3) β slay, bye πβ¨
π¦ 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