From d7140b662ffd86ca4199f1a589437ea7abe93b99 Mon Sep 17 00:00:00 2001 From: Dmitri Naumov <github@naumov.de> Date: Sun, 17 Feb 2019 23:54:55 +0100 Subject: [PATCH] [BL] Remove ifdef for VisualStudio 2008. [[noreturn]] attribute is supported by now. --- BaseLib/ConfigTree.h | 7 +------ BaseLib/Error.h | 8 -------- 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/BaseLib/ConfigTree.h b/BaseLib/ConfigTree.h index e4cfe1825e3..b56d15010d2 100644 --- a/BaseLib/ConfigTree.h +++ b/BaseLib/ConfigTree.h @@ -545,12 +545,7 @@ private: * * This method only acts as a helper method and throws std::runtime_error. */ -#if defined(_MSC_VER) && _MSC_VER < 1500 - __declspec(noreturn) -#else - [[noreturn]] -#endif - void error(std::string const& message) const; + [[noreturn]] void error(std::string const& message) const; //! Called for printing warning messages. Will call the warning callback. //! This method only acts as a helper method. diff --git a/BaseLib/Error.h b/BaseLib/Error.h index 05d5dd78e8e..e563d4b9017 100644 --- a/BaseLib/Error.h +++ b/BaseLib/Error.h @@ -19,11 +19,7 @@ namespace BaseLib namespace detail { template <typename Msg> -#if defined(_MSC_VER) && _MSC_VER < 1500 -__declspec(noreturn) -#else [[noreturn]] -#endif bool error_impl(Msg&& msg) { ERR("%s", msg.data()); @@ -43,11 +39,7 @@ namespace BaseLib namespace detail { template <typename Msg> -#if defined(_MSC_VER) && _MSC_VER < 1500 -__declspec(noreturn) -#else [[noreturn]] -#endif bool error_impl(Msg&& msg) { throw std::runtime_error(std::forward<Msg>(msg)); -- GitLab