aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-parser.c
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2011-12-20 20:44:13 +0000
committerJoseph Myers <jsm28@gcc.gnu.org>2011-12-20 20:44:13 +0000
commit48b0b19630a19eaab06efd305387b930f94fc5d3 (patch)
tree79d9fc73e458081edfd36bdc00b3cb1ba3d1c859 /gcc/c-parser.c
parentd8fa39bfc87c62cdd4970027dedbd982cc2049e1 (diff)
downloadgcc-48b0b19630a19eaab06efd305387b930f94fc5d3.zip
gcc-48b0b19630a19eaab06efd305387b930f94fc5d3.tar.gz
gcc-48b0b19630a19eaab06efd305387b930f94fc5d3.tar.bz2
gcc:
* c-decl.c (diagnose_mismatched_decls, grokdeclarator, grokfield) (finish_struct): Refer to C11 in comments. Use flag_isoc11. * c-parser.c (c_parser_static_assert_declaration) (c_parser_static_assert_declaration_no_semi, c_parser_declspecs) (c_parser_alignas_specifier, c_parser_alignof_expression): Refer to C11 in comments. Use flag_isoc11. * c-typeck.c (comptypes_check_different_types): Refer to C11 in comment. * doc/cpp.texi (Overview): Refer to -std=c11 instead of -std=c1x. * doc/cppopts.texi (-std=c11, -std=gnu11): Document in preference to -std=c1x and -std=gnu1x. * doc/extend.texi (Inline, Alternate Keywords, Other Builtins) (__builtin_complex, Unnamed Fields): Refer to -std=c11 and C11 instead of -std=c1x and C1X. * doc/invoke.texi (-std=c11, -std=iso9899:2011): Document in preference to -std=c1x. (-std=gnu11): Document in preference to -std=gnu1x. * doc/standards.texi: Document C11 instead of C1X. Document C11 as actual standard. Document headers required from freestanding C11 implementations. * ginclude/float.h, ginclude/stddef.h: Test __STDC_VERSION__ >= 201112L for C11. Update comments to refer to C11. gcc/c-family: * c-common.c (flag_isoc99): Update comment to refer to C11. (flag_isoc1x): Change to flag_isoc11. * c-common.h (flag_isoc99): Update comment to refer to C11. (flag_isoc1x): Change to flag_isoc11. * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to C11. * c-opts.c (set_std_c1x): Change to set_std_c11. (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11. Call set_std_c11. (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11. (set_std_c1): Use CLK_STDC11 and CLK_GNUC11. * c.opt (std=c1x): Change to std=c11. Document as non-draft standard. (std=c1x, std=iso9899:2011): Add as aliases of std=c11. (std=gnu1x): Change to std=gnu11. Refer to non-draft standard. (std=gnu1x): Make alias of std=gnu11. gcc/testsuite: * gcc.dg/c11-version-1.c, gcc.dg/c11-version-2.c, gcc.dg/c94-version-1.c, gcc.dg/c99-version-1.c, gcc.dg/gnu11-version-1.c: New tests. libcpp: * include/cpplib.h (CLK_GNUC1X): Change to CLK_GNUC11. (CLK_STDC1X): Change to CLK_STDC11. * init.c (lang_defaults): Update comments. (cpp_init_builtins): Update language tests. Use 201112L for C11 __STDC_VERSION__. From-SVN: r182551
Diffstat (limited to 'gcc/c-parser.c')
-rw-r--r--gcc/c-parser.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/gcc/c-parser.c b/gcc/c-parser.c
index 0a268a6..867ab41 100644
--- a/gcc/c-parser.c
+++ b/gcc/c-parser.c
@@ -1796,7 +1796,7 @@ c_parser_asm_definition (c_parser *parser)
c_parser_skip_until_found (parser, CPP_SEMICOLON, "expected %<;%>");
}
-/* Parse a static assertion (C1X N1425 6.7.10).
+/* Parse a static assertion (C11 6.7.10).
static_assert-declaration:
static_assert-declaration-no-semi ;
@@ -1811,7 +1811,7 @@ c_parser_static_assert_declaration (c_parser *parser)
c_parser_skip_to_end_of_block_or_statement (parser);
}
-/* Parse a static assertion (C1X N1425 6.7.10), without the trailing
+/* Parse a static assertion (C11 6.7.10), without the trailing
semicolon.
static_assert-declaration-no-semi:
@@ -1827,7 +1827,7 @@ c_parser_static_assert_declaration_no_semi (c_parser *parser)
gcc_assert (c_parser_next_token_is_keyword (parser, RID_STATIC_ASSERT));
assert_loc = c_parser_peek_token (parser)->location;
- if (!flag_isoc1x)
+ if (!flag_isoc11)
{
if (flag_isoc99)
pedwarn (assert_loc, OPT_pedantic,
@@ -1902,7 +1902,7 @@ c_parser_static_assert_declaration_no_semi (c_parser *parser)
Function specifiers (inline) are from C99, and are currently
handled as storage class specifiers, as is __thread. Alignment
- specifiers are from C1X.
+ specifiers are from C11.
C90 6.5.1, C99 6.7.1:
storage-class-specifier:
@@ -1917,7 +1917,7 @@ c_parser_static_assert_declaration_no_semi (c_parser *parser)
inline
_Noreturn
- (_Noreturn is new in C1X.)
+ (_Noreturn is new in C11.)
C90 6.5.2, C99 6.7.2:
type-specifier:
@@ -2768,7 +2768,7 @@ c_parser_typeof_specifier (c_parser *parser)
/* Parse an alignment-specifier.
- C1X 6.7.5:
+ C11 6.7.5:
alignment-specifier:
_Alignas ( type-name )
@@ -2782,7 +2782,7 @@ c_parser_alignas_specifier (c_parser * parser)
location_t loc = c_parser_peek_token (parser)->location;
gcc_assert (c_parser_next_token_is_keyword (parser, RID_ALIGNAS));
c_parser_consume_token (parser);
- if (!flag_isoc1x)
+ if (!flag_isoc11)
{
if (flag_isoc99)
pedwarn (loc, OPT_pedantic,
@@ -5841,7 +5841,7 @@ c_parser_cast_expression (c_parser *parser, struct c_expr *after)
__alignof__ ( type-name )
&& identifier
- (C1X permits _Alignof with type names only.)
+ (C11 permits _Alignof with type names only.)
unary-operator: one of
__extension__ __real__ __imag__
@@ -6038,9 +6038,9 @@ c_parser_alignof_expression (c_parser *parser)
tree alignof_spelling = c_parser_peek_token (parser)->value;
gcc_assert (c_parser_next_token_is_keyword (parser, RID_ALIGNOF));
/* A diagnostic is not required for the use of this identifier in
- the implementation namespace; only diagnose it for the C1X
+ the implementation namespace; only diagnose it for the C11
spelling because of existing code using the other spellings. */
- if (!flag_isoc1x
+ if (!flag_isoc11
&& strcmp (IDENTIFIER_POINTER (alignof_spelling), "_Alignof") == 0)
{
if (flag_isoc99)