Update __cplusplus to match the value in the C++14 DIS preview (D3937).
llvm-svn: 202003
This commit is contained in:
@@ -315,9 +315,11 @@ static void InitializeStandardPredefinedMacros(const TargetInfo &TI,
|
||||
else if (!LangOpts.GNUMode && LangOpts.Digraphs)
|
||||
Builder.defineMacro("__STDC_VERSION__", "199409L");
|
||||
} else {
|
||||
// FIXME: Use the right value for __cplusplus for C++1y once one is chosen.
|
||||
if (LangOpts.CPlusPlus1y)
|
||||
Builder.defineMacro("__cplusplus", "201305L");
|
||||
// C++1y [cpp.predefined]p1:
|
||||
// The name __cplusplus is defined to the value 201402L when compiling a
|
||||
// C++ translation unit.
|
||||
if (LangOpts.CPlusPlus1y)
|
||||
Builder.defineMacro("__cplusplus", "201402L");
|
||||
// C++11 [cpp.predefined]p1:
|
||||
// The name __cplusplus is defined to the value 201103L when compiling a
|
||||
// C++ translation unit.
|
||||
|
||||
Reference in New Issue
Block a user