diff --git a/toolsrc/src/vcpkg_Checks.cpp b/toolsrc/src/vcpkg_Checks.cpp index f02addc081..02d3480a25 100644 --- a/toolsrc/src/vcpkg_Checks.cpp +++ b/toolsrc/src/vcpkg_Checks.cpp @@ -4,7 +4,7 @@ namespace vcpkg::Checks { - void unreachable() + __declspec(noreturn) void unreachable() { System::println(System::color::error, "Error: Unreachable code was reached"); #ifndef NDEBUG @@ -14,13 +14,13 @@ namespace vcpkg::Checks #endif } - void exit_with_message(const char* errorMessage) + __declspec(noreturn) void exit_with_message(const char* errorMessage) { System::println(System::color::error, errorMessage); exit(EXIT_FAILURE); } - void throw_with_message(const char* errorMessage) + __declspec(noreturn) void throw_with_message(const char* errorMessage) { throw std::runtime_error(errorMessage); }