xref: /llvm-project/libcxx/include/cstdbool (revision f69585235ec85d54e0f3fc41b2d5700430907f99)
1// -*- C++ -*-
2//===----------------------------------------------------------------------===//
3//
4// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
5// See https://llvm.org/LICENSE.txt for license information.
6// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7//
8//===----------------------------------------------------------------------===//
9
10#ifndef _LIBCPP_CSTDBOOL
11#define _LIBCPP_CSTDBOOL
12
13/*
14    cstdbool synopsis
15
16Macros:
17
18    __bool_true_false_are_defined
19
20*/
21
22#if __cplusplus < 201103L && defined(_LIBCPP_USE_FROZEN_CXX03_HEADERS)
23#  include <__cxx03/cstdbool>
24#else
25#  include <__config>
26
27#  if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
28#    pragma GCC system_header
29#  endif
30
31#  undef __bool_true_false_are_defined
32#  define __bool_true_false_are_defined 1
33
34#  if _LIBCPP_STD_VER >= 20
35
36using __standard_header_cstdbool _LIBCPP_DEPRECATED_("removed in C++20.") _LIBCPP_NODEBUG = void;
37using __use_standard_header_cstdbool _LIBCPP_NODEBUG                                      = __standard_header_cstdbool;
38
39#  elif _LIBCPP_STD_VER >= 17
40
41using __standard_header_cstdbool _LIBCPP_DEPRECATED _LIBCPP_NODEBUG = void;
42using __use_standard_header_cstdbool _LIBCPP_NODEBUG                = __standard_header_cstdbool;
43
44#  endif
45#endif // __cplusplus < 201103L && defined(_LIBCPP_USE_FROZEN_CXX03_HEADERS)
46
47#endif // _LIBCPP_CSTDBOOL
48