summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bindings/python/clang/cindex.py2
-rw-r--r--docs/LanguageExtensions.html24
-rw-r--r--include/clang-c/Index.h2
-rw-r--r--include/clang/AST/Expr.h4
-rw-r--r--include/clang/AST/Type.h2
-rw-r--r--include/clang/Basic/DiagnosticGroups.td4
-rw-r--r--include/clang/Basic/DiagnosticParseKinds.td12
-rw-r--r--include/clang/Basic/LangOptions.def2
-rw-r--r--include/clang/Basic/Specifiers.h2
-rw-r--r--include/clang/Basic/TokenKinds.def2
-rw-r--r--include/clang/Frontend/LangStandard.h6
-rw-r--r--include/clang/Frontend/LangStandards.def12
-rw-r--r--lib/AST/ExprClassification.cpp2
-rw-r--r--lib/Basic/IdentifierTable.cpp4
-rw-r--r--lib/Frontend/CompilerInvocation.cpp2
-rw-r--r--lib/Frontend/InitPreprocessor.cpp2
-rw-r--r--lib/Lex/PPMacroExpansion.cpp10
-rw-r--r--lib/Parse/ParseDecl.cpp22
-rw-r--r--lib/Parse/ParseDeclCXX.cpp8
-rw-r--r--lib/Parse/ParseExpr.cpp16
-rw-r--r--lib/Parse/ParseTentative.cpp2
-rw-r--r--lib/Sema/SemaExpr.cpp10
22 files changed, 76 insertions, 76 deletions
diff --git a/bindings/python/clang/cindex.py b/bindings/python/clang/cindex.py
index cd6ab45496..1dd0010fc9 100644
--- a/bindings/python/clang/cindex.py
+++ b/bindings/python/clang/cindex.py
@@ -607,7 +607,7 @@ CursorKind.ADDR_LABEL_EXPR = CursorKind(120)
# This is the GNU Statement Expression extension: ({int X=4; X;})
CursorKind.StmtExpr = CursorKind(121)
-# Represents a C1X generic selection.
+# Represents a C11 generic selection.
CursorKind.GENERIC_SELECTION_EXPR = CursorKind(122)
# Implements the GNU __null extension, which is a name for a null
diff --git a/docs/LanguageExtensions.html b/docs/LanguageExtensions.html
index f8c0d4f167..1218d46640 100644
--- a/docs/LanguageExtensions.html
+++ b/docs/LanguageExtensions.html
@@ -72,11 +72,11 @@
<li><a href="#cxx_user_literals">C++11 user-defined literals</a></li>
<li><a href="#cxx_variadic_templates">C++11 variadic templates</a></li>
</ul></li>
- <li><a href="#c1x">C1X</a>
+ <li><a href="#c11">C11</a>
<ul>
- <li><a href="#c_alignas">C1X alignment specifiers</a></li>
- <li><a href="#c_generic_selections">C1X generic selections</a></li>
- <li><a href="#c_static_assert">C1X <tt>_Static_assert()</tt></a></li>
+ <li><a href="#c_alignas">C11 alignment specifiers</a></li>
+ <li><a href="#c_generic_selections">C11 generic selections</a></li>
+ <li><a href="#c_static_assert">C11 <tt>_Static_assert()</tt></a></li>
</ul></li>
</ul> </li>
<li><a href="#checking_type_traits">Checks for Type Traits</a></li>
@@ -659,33 +659,33 @@ support for Unicode string literals is enabled.</p>
<tt>__has_extension(cxx_variadic_templates)</tt> to determine if support
for variadic templates is enabled.</p>
-<h3 id="c1x">C1X</h3>
+<h3 id="c11">C11</h3>
<p>The features listed below are slated for inclusion in the upcoming
-C1X standard. As a result, all these features are enabled
-with the <tt>-std=c1x</tt> option when compiling C code.</p>
+C11 standard. As a result, all these features are enabled
+with the <tt>-std=c11</tt> option when compiling C code.</p>
-<h4 id="c_alignas">C1X alignment specifiers</h4>
+<h4 id="c_alignas">C11 alignment specifiers</h4>
<p>Use <tt>__has_feature(c_alignas)</tt> or <tt>__has_extension(c_alignas)</tt>
to determine if support for alignment specifiers using <tt>_Alignas</tt>
is enabled.</p>
-<h4 id="c_generic_selections">C1X generic selections</h4>
+<h4 id="c_generic_selections">C11 generic selections</h4>
<p>Use <tt>__has_feature(c_generic_selections)</tt> or
<tt>__has_extension(c_generic_selections)</tt> to determine if support for
generic selections is enabled.</p>
-<p>As an extension, the C1X generic selection expression is available in all
+<p>As an extension, the C11 generic selection expression is available in all
languages supported by Clang. The syntax is the same as that given in the
-C1X draft standard.</p>
+C11 standard.</p>
<p>In C, type compatibility is decided according to the rules given in the
appropriate standard, but in C++, which lacks the type compatibility rules
used in C, types are considered compatible only if they are equivalent.</p>
-<h4 id="c_static_assert">C1X <tt>_Static_assert()</tt></h4>
+<h4 id="c_static_assert">C11 <tt>_Static_assert()</tt></h4>
<p>Use <tt>__has_feature(c_static_assert)</tt> or
<tt>__has_extension(c_static_assert)</tt> to determine if support for
diff --git a/include/clang-c/Index.h b/include/clang-c/Index.h
index d9d027e2a6..92315a387f 100644
--- a/include/clang-c/Index.h
+++ b/include/clang-c/Index.h
@@ -1617,7 +1617,7 @@ enum CXCursorKind {
*/
CXCursor_StmtExpr = 121,
- /** \brief Represents a C1X generic selection.
+ /** \brief Represents a C11 generic selection.
*/
CXCursor_GenericSelectionExpr = 122,
diff --git a/include/clang/AST/Expr.h b/include/clang/AST/Expr.h
index 9c86c16c4e..9c189e2d06 100644
--- a/include/clang/AST/Expr.h
+++ b/include/clang/AST/Expr.h
@@ -3948,9 +3948,9 @@ public:
};
-/// \brief Represents a C1X generic selection.
+/// \brief Represents a C11 generic selection.
///
-/// A generic selection (C1X 6.5.1.1) contains an unevaluated controlling
+/// A generic selection (C11 6.5.1.1) contains an unevaluated controlling
/// expression, followed by one or more generic associations. Each generic
/// association specifies a type name and an expression, or "default" and an
/// expression (in which case it is known as a default generic association).
diff --git a/include/clang/AST/Type.h b/include/clang/AST/Type.h
index de5839688d..58a112cadf 100644
--- a/include/clang/AST/Type.h
+++ b/include/clang/AST/Type.h
@@ -1455,7 +1455,7 @@ public:
bool isCARCBridgableType() const;
bool isTemplateTypeParmType() const; // C++ template type parameter
bool isNullPtrType() const; // C++0x nullptr_t
- bool isAtomicType() const; // C1X _Atomic()
+ bool isAtomicType() const; // C11 _Atomic()
/// Determines if this type, which must satisfy
/// isObjCLifetimeType(), is implicitly __unsafe_unretained rather
diff --git a/include/clang/Basic/DiagnosticGroups.td b/include/clang/Basic/DiagnosticGroups.td
index 0f3d67b53e..c54abaa1dc 100644
--- a/include/clang/Basic/DiagnosticGroups.td
+++ b/include/clang/Basic/DiagnosticGroups.td
@@ -343,8 +343,8 @@ def : DiagGroup<"c++0x-extensions", [CXX11]>;
def DelegatingCtorCycles :
DiagGroup<"delegating-ctor-cycles">;
-// A warning group for warnings about using C1X features as extensions.
-def C1X : DiagGroup<"c1x-extensions">;
+// A warning group for warnings about using C11 features as extensions.
+def C11 : DiagGroup<"c11-extensions">;
// A warning group for warnings about using C99 features as extensions.
def C99 : DiagGroup<"c99-extensions">;
diff --git a/include/clang/Basic/DiagnosticParseKinds.td b/include/clang/Basic/DiagnosticParseKinds.td
index 8c3d43b249..a7f614fe70 100644
--- a/include/clang/Basic/DiagnosticParseKinds.td
+++ b/include/clang/Basic/DiagnosticParseKinds.td
@@ -79,15 +79,15 @@ def warn_microsoft_dependent_exists : Warning<
"dependent %select{__if_not_exists|__if_exists}0 declarations are ignored">,
InGroup<DiagGroup<"microsoft-exists">>;
-def ext_c1x_generic_selection : Extension<
- "generic selections are a C1X-specific feature">, InGroup<C1X>;
+def ext_c11_generic_selection : Extension<
+ "generic selections are a C11-specific feature">, InGroup<C11>;
def err_duplicate_default_assoc : Error<
"duplicate default generic association">;
def note_previous_default_assoc : Note<
"previous default generic association is here">;
-def ext_c1x_alignas : Extension<
- "_Alignas is a C1X-specific feature">, InGroup<C1X>;
+def ext_c11_alignas : Extension<
+ "_Alignas is a C11-specific feature">, InGroup<C11>;
def ext_gnu_indirect_goto : Extension<
"use of GNU indirect-goto extension">, InGroup<GNU>;
@@ -304,8 +304,8 @@ def err_unexected_colon_in_nested_name_spec : Error<
"unexpected ':' in nested name specifier">;
def err_bool_redeclaration : Error<
"redeclaration of C++ built-in type 'bool'">;
-def ext_c1x_static_assert : Extension<
- "_Static_assert is a C1X-specific feature">, InGroup<C1X>;
+def ext_c11_static_assert : Extension<
+ "_Static_assert is a C11-specific feature">, InGroup<C11>;
def warn_cxx98_compat_static_assert : Warning<
"static_assert declarations are incompatible with C++98">,
InGroup<CXX98Compat>, DefaultIgnore;
diff --git a/include/clang/Basic/LangOptions.def b/include/clang/Basic/LangOptions.def
index 9d92ea5608..1f7bcd6f94 100644
--- a/include/clang/Basic/LangOptions.def
+++ b/include/clang/Basic/LangOptions.def
@@ -42,7 +42,7 @@
#endif
LANGOPT(C99 , 1, 0, "C99")
-LANGOPT(C1X , 1, 0, "C1X")
+LANGOPT(C11 , 1, 0, "C11")
LANGOPT(MicrosoftExt , 1, 0, "Microsoft extensions")
LANGOPT(MicrosoftMode , 1, 0, "Microsoft compatibility mode")
LANGOPT(Borland , 1, 0, "Borland extensions")
diff --git a/include/clang/Basic/Specifiers.h b/include/clang/Basic/Specifiers.h
index 2a95d6165c..390e5e5f4d 100644
--- a/include/clang/Basic/Specifiers.h
+++ b/include/clang/Basic/Specifiers.h
@@ -58,7 +58,7 @@ namespace clang {
TST_underlyingType, // __underlying_type for C++0x
TST_auto, // C++0x auto
TST_unknown_anytype, // __unknown_anytype extension
- TST_atomic, // C1X _Atomic
+ TST_atomic, // C11 _Atomic
TST_error // erroneous type
};
diff --git a/include/clang/Basic/TokenKinds.def b/include/clang/Basic/TokenKinds.def
index e9b772cdde..bb905a4ae8 100644
--- a/include/clang/Basic/TokenKinds.def
+++ b/include/clang/Basic/TokenKinds.def
@@ -204,7 +204,7 @@ PUNCTUATOR(greatergreatergreater, ">>>")
// is a keyword in the implementation namespace that should
// always be treated as a keyword
// KEYC99 - This is a keyword introduced to C in C99
-// KEYC1X - This is a keyword introduced to C in C1X
+// KEYC11 - This is a keyword introduced to C in C11
// KEYCXX - This is a C++ keyword, or a C++-specific keyword in the
// implementation namespace
// KEYNOCXX - This is a keyword in every non-C++ dialect.
diff --git a/include/clang/Frontend/LangStandard.h b/include/clang/Frontend/LangStandard.h
index de2800cd73..e6f44032ac 100644
--- a/include/clang/Frontend/LangStandard.h
+++ b/include/clang/Frontend/LangStandard.h
@@ -21,7 +21,7 @@ enum LangFeatures {
BCPLComment = (1 << 0),
C89 = (1 << 1),
C99 = (1 << 2),
- C1X = (1 << 3),
+ C11 = (1 << 3),
CPlusPlus = (1 << 4),
CPlusPlus0x = (1 << 5),
Digraphs = (1 << 6),
@@ -62,8 +62,8 @@ public:
/// isC99 - Language is a superset of C99.
bool isC99() const { return Flags & frontend::C99; }
- /// isC1X - Language is a superset of C1X.
- bool isC1X() const { return Flags & frontend::C1X; }
+ /// isC11 - Language is a superset of C11.
+ bool isC11() const { return Flags & frontend::C11; }
/// isCPlusPlus - Language is a C++ variant.
bool isCPlusPlus() const { return Flags & frontend::CPlusPlus; }
diff --git a/include/clang/Frontend/LangStandards.def b/include/clang/Frontend/LangStandards.def
index edac6cfe8d..4bcff4a92b 100644
--- a/include/clang/Frontend/LangStandards.def
+++ b/include/clang/Frontend/LangStandards.def
@@ -65,23 +65,23 @@ LANGSTANDARD(gnu9x, "gnu9x",
// C11 modes
LANGSTANDARD(c11, "c11",
"ISO C 2011",
- BCPLComment | C99 | C1X | Digraphs | HexFloat)
+ BCPLComment | C99 | C11 | Digraphs | HexFloat)
LANGSTANDARD(c1x, "c1x",
"ISO C 2011",
- BCPLComment | C99 | C1X | Digraphs | HexFloat)
+ BCPLComment | C99 | C11 | Digraphs | HexFloat)
LANGSTANDARD(iso9899_2011,
"iso9899:2011", "ISO C 2011",
- BCPLComment | C99 | C1X | Digraphs | HexFloat)
+ BCPLComment | C99 | C11 | Digraphs | HexFloat)
LANGSTANDARD(iso9899_201x,
"iso9899:2011", "ISO C 2011",
- BCPLComment | C99 | C1X | Digraphs | HexFloat)
+ BCPLComment | C99 | C11 | Digraphs | HexFloat)
LANGSTANDARD(gnu11, "gnu11",
"ISO C 2011 with GNU extensions",
- BCPLComment | C99 | C1X | Digraphs | GNUMode | HexFloat)
+ BCPLComment | C99 | C11 | Digraphs | GNUMode | HexFloat)
LANGSTANDARD(gnu1x, "gnu1x",
"ISO C 2011 with GNU extensions",
- BCPLComment | C99 | C1X | Digraphs | GNUMode | HexFloat)
+ BCPLComment | C99 | C11 | Digraphs | GNUMode | HexFloat)
// C++ modes
LANGSTANDARD(cxx98, "c++98",
diff --git a/lib/AST/ExprClassification.cpp b/lib/AST/ExprClassification.cpp
index f5ee3e5dee..60e6f96c96 100644
--- a/lib/AST/ExprClassification.cpp
+++ b/lib/AST/ExprClassification.cpp
@@ -247,7 +247,7 @@ static Cl::Kinds ClassifyInternal(ASTContext &Ctx, const Expr *E) {
case Expr::ParenExprClass:
return ClassifyInternal(Ctx, cast<ParenExpr>(E)->getSubExpr());
- // C1X 6.5.1.1p4: [A generic selection] is an lvalue, a function designator,
+ // C11 6.5.1.1p4: [A generic selection] is an lvalue, a function designator,
// or a void expression if its result expression is, respectively, an
// lvalue, a function designator, or a void expression.
case Expr::GenericSelectionExprClass:
diff --git a/lib/Basic/IdentifierTable.cpp b/lib/Basic/IdentifierTable.cpp
index f5b417c72c..690a1f5a84 100644
--- a/lib/Basic/IdentifierTable.cpp
+++ b/lib/Basic/IdentifierTable.cpp
@@ -95,7 +95,7 @@ namespace {
KEYNOCXX = 0x80,
KEYBORLAND = 0x100,
KEYOPENCL = 0x200,
- KEYC1X = 0x400,
+ KEYC11 = 0x400,
KEYARC = 0x800,
KEYALL = 0x0fff
};
@@ -124,7 +124,7 @@ static void AddKeyword(StringRef Keyword,
else if (LangOpts.AltiVec && (Flags & KEYALTIVEC)) AddResult = 2;
else if (LangOpts.OpenCL && (Flags & KEYOPENCL)) AddResult = 2;
else if (!LangOpts.CPlusPlus && (Flags & KEYNOCXX)) AddResult = 2;
- else if (LangOpts.C1X && (Flags & KEYC1X)) AddResult = 2;
+ else if (LangOpts.C11 && (Flags & KEYC11)) AddResult = 2;
// We treat bridge casts as objective-C keywords so we can warn on them
// in non-arc mode.
else if (LangOpts.ObjC2 && (Flags & KEYARC)) AddResult = 2;
diff --git a/lib/Frontend/CompilerInvocation.cpp b/lib/Frontend/CompilerInvocation.cpp
index 18b247c9b9..caeb416a59 100644
--- a/lib/Frontend/CompilerInvocation.cpp
+++ b/lib/Frontend/CompilerInvocation.cpp
@@ -1615,7 +1615,7 @@ void CompilerInvocation::setLangDefaults(LangOptions &Opts, InputKind IK,
const LangStandard &Std = LangStandard::getLangStandardForKind(LangStd);
Opts.BCPLComment = Std.hasBCPLComments();
Opts.C99 = Std.isC99();
- Opts.C1X = Std.isC1X();
+ Opts.C11 = Std.isC11();
Opts.CPlusPlus = Std.isCPlusPlus();
Opts.CPlusPlus0x = Std.isCPlusPlus0x();
Opts.Digraphs = Std.hasDigraphs();
diff --git a/lib/Frontend/InitPreprocessor.cpp b/lib/Frontend/InitPreprocessor.cpp
index 61d1748686..ad12e3dc3c 100644
--- a/lib/Frontend/InitPreprocessor.cpp
+++ b/lib/Frontend/InitPreprocessor.cpp
@@ -270,7 +270,7 @@ static void InitializeStandardPredefinedMacros(const TargetInfo &TI,
// FIXME: C1x doesn't have a defined version number yet, so pick something
// that is the minimum possible according to their placeholder scheme
// 201ymmL.
- if (LangOpts.C1X)
+ if (LangOpts.C11)
Builder.defineMacro("__STDC_VERSION__", "201001L");
else if (LangOpts.C99)
Builder.defineMacro("__STDC_VERSION__", "199901L");
diff --git a/lib/Lex/PPMacroExpansion.cpp b/lib/Lex/PPMacroExpansion.cpp
index c5041ddb9b..a0d203f8c8 100644
--- a/lib/Lex/PPMacroExpansion.cpp
+++ b/lib/Lex/PPMacroExpansion.cpp
@@ -621,10 +621,10 @@ static bool HasFeature(const Preprocessor &PP, const IdentifierInfo *II) {
.Case("ownership_returns", true)
.Case("ownership_takes", true)
.Case("arc_cf_code_audited", true)
- // C1X features
- .Case("c_alignas", LangOpts.C1X)
- .Case("c_generic_selections", LangOpts.C1X)
- .Case("c_static_assert", LangOpts.C1X)
+ // C11 features
+ .Case("c_alignas", LangOpts.C11)
+ .Case("c_generic_selections", LangOpts.C11)
+ .Case("c_static_assert", LangOpts.C11)
// C++0x features
.Case("cxx_access_control_sfinae", LangOpts.CPlusPlus0x)
.Case("cxx_alias_templates", LangOpts.CPlusPlus0x)
@@ -718,7 +718,7 @@ static bool HasExtension(const Preprocessor &PP, const IdentifierInfo *II) {
// Because we inherit the feature list from HasFeature, this string switch
// must be less restrictive than HasFeature's.
return llvm::StringSwitch<bool>(II->getName())
- // C1X features supported by other languages as extensions.
+ // C11 features supported by other languages as extensions.
.Case("c_alignas", true)
.Case("c_generic_selections", true)
.Case("c_static_assert", true)
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp
index 9644d62bd2..94f7b9bb7d 100644
--- a/lib/Parse/ParseDecl.cpp
+++ b/lib/Parse/ParseDecl.cpp
@@ -883,7 +883,7 @@ void Parser::DiagnoseProhibitedAttributes(ParsedAttributesWithRange &attrs) {
/// [C++] namespace-definition
/// [C++] using-directive
/// [C++] using-declaration
-/// [C++0x/C1X] static_assert-declaration
+/// [C++0x/C11] static_assert-declaration
/// others... [FIXME]
///
Parser::DeclGroupPtrTy Parser::ParseDeclaration(StmtVector &Stmts,
@@ -1566,8 +1566,8 @@ Parser::getDeclSpecContextFromDeclaratorContext(unsigned Context) {
/// FIXME: Simply returns an alignof() expression if the argument is a
/// type. Ideally, the type should be propagated directly into Sema.
///
-/// [C1X] type-id
-/// [C1X] constant-expression
+/// [C11] type-id
+/// [C11] constant-expression
/// [C++0x] type-id ...[opt]
/// [C++0x] assignment-expression ...[opt]
ExprResult Parser::ParseAlignArgument(SourceLocation Start,
@@ -1592,8 +1592,8 @@ ExprResult Parser::ParseAlignArgument(SourceLocation Start,
/// attribute to Attrs.
///
/// alignment-specifier:
-/// [C1X] '_Alignas' '(' type-id ')'
-/// [C1X] '_Alignas' '(' constant-expression ')'
+/// [C11] '_Alignas' '(' type-id ')'
+/// [C11] '_Alignas' '(' constant-expression ')'
/// [C++0x] 'alignas' '(' type-id ...[opt] ')'
/// [C++0x] 'alignas' '(' assignment-expression ...[opt] ')'
void Parser::ParseAlignmentSpecifier(ParsedAttributes &Attrs,
@@ -1636,7 +1636,7 @@ void Parser::ParseAlignmentSpecifier(ParsedAttributes &Attrs,
/// storage-class-specifier declaration-specifiers[opt]
/// type-specifier declaration-specifiers[opt]
/// [C99] function-specifier declaration-specifiers[opt]
-/// [C1X] alignment-specifier declaration-specifiers[opt]
+/// [C11] alignment-specifier declaration-specifiers[opt]
/// [GNU] attributes declaration-specifiers[opt]
/// [Clang] '__module_private__' declaration-specifiers[opt]
///
@@ -2085,8 +2085,8 @@ void Parser::ParseDeclarationSpecifiers(DeclSpec &DS,
// alignment-specifier
case tok::kw__Alignas:
- if (!getLang().C1X)
- Diag(Tok, diag::ext_c1x_alignas);
+ if (!getLang().C11)
+ Diag(Tok, diag::ext_c11_alignas);
ParseAlignmentSpecifier(DS.getAttributes());
continue;
@@ -3341,7 +3341,7 @@ bool Parser::isTypeSpecifierQualifier() {
case tok::kw_private:
return getLang().OpenCL;
- // C1x _Atomic()
+ // C11 _Atomic()
case tok::kw__Atomic:
return true;
}
@@ -3465,7 +3465,7 @@ bool Parser::isDeclarationSpecifier(bool DisambiguatingWithExpression) {
case tok::annot_decltype:
return true;
- // C1x _Atomic()
+ // C11 _Atomic()
case tok::kw__Atomic:
return true;
@@ -4670,7 +4670,7 @@ void Parser::ParseTypeofSpecifier(DeclSpec &DS) {
Diag(StartLoc, DiagID) << PrevSpec;
}
-/// [C1X] atomic-specifier:
+/// [C11] atomic-specifier:
/// _Atomic ( type-name )
///
void Parser::ParseAtomicSpecifier(DeclSpec &DS) {
diff --git a/lib/Parse/ParseDeclCXX.cpp b/lib/Parse/ParseDeclCXX.cpp
index 58e16bfff4..5bae0e4d2c 100644
--- a/lib/Parse/ParseDeclCXX.cpp
+++ b/lib/Parse/ParseDeclCXX.cpp
@@ -573,20 +573,20 @@ Decl *Parser::ParseUsingDeclaration(unsigned Context,
IsTypeName, TypenameLoc);
}
-/// ParseStaticAssertDeclaration - Parse C++0x or C1X static_assert-declaration.
+/// ParseStaticAssertDeclaration - Parse C++0x or C11 static_assert-declaration.
///
/// [C++0x] static_assert-declaration:
/// static_assert ( constant-expression , string-literal ) ;
///
-/// [C1X] static_assert-declaration:
+/// [C11] static_assert-declaration:
/// _Static_assert ( constant-expression , string-literal ) ;
///
Decl *Parser::ParseStaticAssertDeclaration(SourceLocation &DeclEnd){
assert((Tok.is(tok::kw_static_assert) || Tok.is(tok::kw__Static_assert)) &&
"Not a static_assert declaration");
- if (Tok.is(tok::kw__Static_assert) && !getLang().C1X)
- Diag(Tok, diag::ext_c1x_static_assert);
+ if (Tok.is(tok::kw__Static_assert) && !getLang().C11)
+ Diag(Tok, diag::ext_c11_static_assert);
if (Tok.is(tok::kw_static_assert))
Diag(Tok, diag::warn_cxx98_compat_static_assert);
diff --git a/lib/Parse/ParseExpr.cpp b/lib/Parse/ParseExpr.cpp
index 8af7204cd1..0dd48a2946 100644
--- a/lib/Parse/ParseExpr.cpp
+++ b/lib/Parse/ParseExpr.cpp
@@ -466,7 +466,7 @@ ExprResult Parser::ParseCastExpression(bool isUnaryExpression,
/// [C++] boolean-literal [C++ 2.13.5]
/// [C++0x] 'nullptr' [C++0x 2.14.7]
/// '(' expression ')'
-/// [C1X] generic-selection
+/// [C11] generic-selection
/// '__func__' [C99 6.4.2.2]
/// [GNU] '__FUNCTION__'
/// [GNU] '__PRETTY_FUNCTION__'
@@ -794,7 +794,7 @@ ExprResult Parser::ParseCastExpression(bool isUnaryExpression,
case tok::utf32_string_literal:
Res = ParseStringLiteralExpression();
break;
- case tok::kw__Generic: // primary-expression: generic-selection [C1X 6.5.1]
+ case tok::kw__Generic: // primary-expression: generic-selection [C11 6.5.1]
Res = ParseGenericSelectionExpression();
break;
case tok::kw___builtin_va_arg:
@@ -2050,8 +2050,8 @@ ExprResult Parser::ParseStringLiteralExpression() {
return Actions.ActOnStringLiteral(&StringToks[0], StringToks.size());
}
-/// ParseGenericSelectionExpression - Parse a C1X generic-selection
-/// [C1X 6.5.1.1].
+/// ParseGenericSelectionExpression - Parse a C11 generic-selection
+/// [C11 6.5.1.1].
///
/// generic-selection:
/// _Generic ( assignment-expression , generic-assoc-list )
@@ -2065,8 +2065,8 @@ ExprResult Parser::ParseGenericSelectionExpression() {
assert(Tok.is(tok::kw__Generic) && "_Generic keyword expected");
SourceLocation KeyLoc = ConsumeToken();
- if (!getLang().C1X)
- Diag(KeyLoc, diag::ext_c1x_generic_selection);
+ if (!getLang().C11)
+ Diag(KeyLoc, diag::ext_c11_generic_selection);
BalancedDelimiterTracker T(*this, tok::l_paren);
if (T.expectAndConsume(diag::err_expected_lparen))
@@ -2074,7 +2074,7 @@ ExprResult Parser::ParseGenericSelectionExpression() {
ExprResult ControllingExpr;
{
- // C1X 6.5.1.1p3 "The controlling expression of a generic selection is
+ // C11 6.5.1.1p3 "The controlling expression of a generic selection is
// not evaluated."
EnterExpressionEvaluationContext Unevaluated(Actions, Sema::Unevaluated);
ControllingExpr = ParseAssignmentExpression();
@@ -2095,7 +2095,7 @@ ExprResult Parser::ParseGenericSelectionExpression() {
while (1) {
ParsedType Ty;
if (Tok.is(tok::kw_default)) {
- // C1X 6.5.1.1p2 "A generic selection shall have no more than one default
+ // C11 6.5.1.1p2 "A generic selection shall have no more than one default
// generic association."
if (!DefaultLoc.isInvalid()) {
Diag(Tok, diag::err_duplicate_default_assoc);
diff --git a/lib/Parse/ParseTentative.cpp b/lib/Parse/ParseTentative.cpp
index 2c9018316a..fe46456040 100644
--- a/lib/Parse/ParseTentative.cpp
+++ b/lib/Parse/ParseTentative.cpp
@@ -1046,7 +1046,7 @@ Parser::TPResult Parser::isCXXDeclarationSpecifier() {
case tok::kw___underlying_type:
return TPResult::True();
- // C1x _Atomic
+ // C11 _Atomic
case tok::kw__Atomic:
return TPResult::True();
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp
index 9d2298a704..126468ee35 100644
--- a/lib/Sema/SemaExpr.cpp
+++ b/lib/Sema/SemaExpr.cpp
@@ -1015,7 +1015,7 @@ Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc,
if (Types[i]->getType()->isDependentType()) {
IsResultDependent = true;
} else {
- // C1X 6.5.1.1p2 "The type name in a generic association shall specify a
+ // C11 6.5.1.1p2 "The type name in a generic association shall specify a
// complete object type other than a variably modified type."
unsigned D = 0;
if (Types[i]->getType()->isIncompleteType())
@@ -1032,7 +1032,7 @@ Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc,
TypeErrorFound = true;
}
- // C1X 6.5.1.1p2 "No two generic associations in the same generic
+ // C11 6.5.1.1p2 "No two generic associations in the same generic
// selection shall specify compatible types."
for (unsigned j = i+1; j < NumAssocs; ++j)
if (Types[j] && !Types[j]->getType()->isDependentType() &&
@@ -1073,7 +1073,7 @@ Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc,
CompatIndices.push_back(i);
}
- // C1X 6.5.1.1p2 "The controlling expression of a generic selection shall have
+ // C11 6.5.1.1p2 "The controlling expression of a generic selection shall have
// type compatible with at most one of the types named in its generic
// association list."
if (CompatIndices.size() > 1) {
@@ -1093,7 +1093,7 @@ Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc,
return ExprError();
}
- // C1X 6.5.1.1p2 "If a generic selection has no default generic association,
+ // C11 6.5.1.1p2 "If a generic selection has no default generic association,
// its controlling expression shall have type compatible with exactly one of
// the types named in its generic association list."
if (DefaultIndex == -1U && CompatIndices.size() == 0) {
@@ -1105,7 +1105,7 @@ Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc,
return ExprError();
}
- // C1X 6.5.1.1p3 "If a generic selection has a generic association with a
+ // C11 6.5.1.1p3 "If a generic selection has a generic association with a
// type name that is compatible with the type of the controlling expression,
// then the result expression of the generic selection is the expression
// in that generic association. Otherwise, the result expression of the