Add FMT_NORETURN to assert_fail prototype. (#1569)

When building with -Werror,-Wmissing-noreturn clang identifies that assert_fail could be declared with the 'noreturn' attribute.
This commit is contained in:
refnum 2020-03-01 01:17:55 +00:00 committed by GitHub
parent bed134a4aa
commit 6ccb2e241b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -253,7 +253,7 @@ namespace internal {
// A workaround for gcc 4.8 to make void_t work in a SFINAE context. // A workaround for gcc 4.8 to make void_t work in a SFINAE context.
template <typename... Ts> struct void_t_impl { using type = void; }; template <typename... Ts> struct void_t_impl { using type = void; };
FMT_API void assert_fail(const char* file, int line, const char* message); FMT_NORETURN FMT_API void assert_fail(const char* file, int line, const char* message);
#ifndef FMT_ASSERT #ifndef FMT_ASSERT
# ifdef NDEBUG # ifdef NDEBUG