]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/boost/predef/language/stdcpp.h
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / boost / boost / predef / language / stdcpp.h
CommitLineData
7c673cae
FG
1/*
2Copyright Rene Rivera 2011-2015
3Distributed under the Boost Software License, Version 1.0.
4(See accompanying file LICENSE_1_0.txt or copy at
5http://www.boost.org/LICENSE_1_0.txt)
6*/
7
8#ifndef BOOST_PREDEF_LANGUAGE_STDCPP_H
9#define BOOST_PREDEF_LANGUAGE_STDCPP_H
10
11#include <boost/predef/version_number.h>
12#include <boost/predef/make.h>
13
f67539c2
TL
14/* tag::reference[]
15= `BOOST_LANG_STDCPP`
7c673cae 16
f67539c2 17http://en.wikipedia.org/wiki/C%2B%2B[Standard {CPP}] language.
7c673cae 18If available, the year of the standard is detected as YYYY.MM.1 from the Epoc date.
f67539c2 19Because of the way the {CPP} standardization process works the
7c673cae
FG
20defined version year will not be the commonly known year of the standard.
21Specifically the defined versions are:
22
f67539c2
TL
23.Detected Version Number vs. {CPP} Standard Year
24[options="header"]
25|===
26| Detected Version Number | Standard Year | {CPP} Standard
27| 27.11.1 | 1998 | ISO/IEC 14882:1998
28| 41.3.1 | 2011 | ISO/IEC 14882:2011
29| 44.2.1 | 2014 | ISO/IEC 14882:2014
30| 47.3.1 | 2017 | ISO/IEC 14882:2017
31|===
7c673cae 32
f67539c2
TL
33[options="header"]
34|===
35| {predef_symbol} | {predef_version}
7c673cae 36
f67539c2 37| `+__cplusplus+` | {predef_detection}
7c673cae 38
f67539c2
TL
39| `+__cplusplus+` | YYYY.MM.1
40|===
41*/ // end::reference[]
7c673cae
FG
42
43#define BOOST_LANG_STDCPP BOOST_VERSION_NUMBER_NOT_AVAILABLE
44
45#if defined(__cplusplus)
46# undef BOOST_LANG_STDCPP
47# if (__cplusplus > 100)
48# define BOOST_LANG_STDCPP BOOST_PREDEF_MAKE_YYYYMM(__cplusplus)
49# else
50# define BOOST_LANG_STDCPP BOOST_VERSION_NUMBER_AVAILABLE
51# endif
52#endif
53
54#if BOOST_LANG_STDCPP
55# define BOOST_LANG_STDCPP_AVAILABLE
56#endif
57
58#define BOOST_LANG_STDCPP_NAME "Standard C++"
59
f67539c2
TL
60/* tag::reference[]
61= `BOOST_LANG_STDCPPCLI`
7c673cae 62
f67539c2 63http://en.wikipedia.org/wiki/C%2B%2B/CLI[Standard {CPP}/CLI] language.
7c673cae
FG
64If available, the year of the standard is detected as YYYY.MM.1 from the Epoc date.
65
f67539c2
TL
66[options="header"]
67|===
68| {predef_symbol} | {predef_version}
7c673cae 69
f67539c2 70| `+__cplusplus_cli+` | {predef_detection}
7c673cae 71
f67539c2
TL
72| `+__cplusplus_cli+` | YYYY.MM.1
73|===
74*/ // end::reference[]
7c673cae
FG
75
76#define BOOST_LANG_STDCPPCLI BOOST_VERSION_NUMBER_NOT_AVAILABLE
77
78#if defined(__cplusplus_cli)
79# undef BOOST_LANG_STDCPPCLI
80# if (__cplusplus_cli > 100)
81# define BOOST_LANG_STDCPPCLI BOOST_PREDEF_MAKE_YYYYMM(__cplusplus_cli)
82# else
83# define BOOST_LANG_STDCPPCLI BOOST_VERSION_NUMBER_AVAILABLE
84# endif
85#endif
86
87#if BOOST_LANG_STDCPPCLI
88# define BOOST_LANG_STDCPPCLI_AVAILABLE
89#endif
90
91#define BOOST_LANG_STDCPPCLI_NAME "Standard C++/CLI"
92
f67539c2
TL
93/* tag::reference[]
94= `BOOST_LANG_STDECPP`
7c673cae 95
f67539c2 96http://en.wikipedia.org/wiki/Embedded_C%2B%2B[Standard Embedded {CPP}] language.
7c673cae 97
f67539c2
TL
98[options="header"]
99|===
100| {predef_symbol} | {predef_version}
7c673cae 101
f67539c2
TL
102| `+__embedded_cplusplus+` | {predef_detection}
103|===
104*/ // end::reference[]
7c673cae
FG
105
106#define BOOST_LANG_STDECPP BOOST_VERSION_NUMBER_NOT_AVAILABLE
107
108#if defined(__embedded_cplusplus)
109# undef BOOST_LANG_STDECPP
110# define BOOST_LANG_STDECPP BOOST_VERSION_NUMBER_AVAILABLE
111#endif
112
113#if BOOST_LANG_STDECPP
114# define BOOST_LANG_STDECPP_AVAILABLE
115#endif
116
117#define BOOST_LANG_STDECPP_NAME "Standard Embedded C++"
118
119#endif
120
121#include <boost/predef/detail/test.h>
122BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDCPP,BOOST_LANG_STDCPP_NAME)
123
124#include <boost/predef/detail/test.h>
125BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDCPPCLI,BOOST_LANG_STDCPPCLI_NAME)
126
127#include <boost/predef/detail/test.h>
128BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDECPP,BOOST_LANG_STDECPP_NAME)