1 //===----------------------------------------------------------------------===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
12 #include <type_traits>
14 #include "test_macros.h"
17 #error SIG_DFL not defined
21 #error SIG_ERR not defined
25 #error SIG_IGN not defined
29 #error SIGABRT not defined
33 #error SIGFPE not defined
37 #error SIGILL not defined
41 #error SIGINT not defined
45 #error SIGSEGV not defined
49 #error SIGTERM not defined
54 std::sig_atomic_t sig
= 0;
56 typedef void (*func
)(int);
57 static_assert((std::is_same
<decltype(std::signal(0, (func
)0)), func
>::value
), "");
58 static_assert((std::is_same
<decltype(std::raise(0)), int>::value
), "");