| //===----------------------------------------------------------------------===// |
| // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
| // See https://llvm.org/LICENSE.txt for license information. |
| // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
| //===----------------------------------------------------------------------===// |
| void (*signal(int sig, void (*func)(int)))(int); |
| #include <__assert> // all public C++ headers provide the assertion handler |
| // <signal.h> is not provided by libc++ |
| #if __has_include(<signal.h>) |
| # error "If libc++ starts defining <signal.h>, the __has_include check should move to libc++'s <signal.h>" |
| #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) |
| # pragma GCC system_header |
| _LIBCPP_BEGIN_NAMESPACE_STD |
| using ::sig_atomic_t _LIBCPP_USING_IF_EXISTS; |
| using ::signal _LIBCPP_USING_IF_EXISTS; |
| using ::raise _LIBCPP_USING_IF_EXISTS; |
| _LIBCPP_END_NAMESPACE_STD |
| #endif // _LIBCPP_CSIGNAL |