aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-decl.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@cygnus.com>1998-12-08 02:26:36 -0800
committerRichard Henderson <rth@gcc.gnu.org>1998-12-08 02:26:36 -0800
commit6271b19158eaaa54134d12bc0dee09903a71b95e (patch)
tree30264eb9cb9687ecf230e615a5c6e5c4b0f3a722 /gcc/c-decl.c
parentf454109fab84bbf19dfdaed3a415f5902398aa2c (diff)
downloadgcc-6271b19158eaaa54134d12bc0dee09903a71b95e.zip
gcc-6271b19158eaaa54134d12bc0dee09903a71b95e.tar.gz
gcc-6271b19158eaaa54134d12bc0dee09903a71b95e.tar.bz2
c-decl.c (flag_isoc9x): Default off.
* c-decl.c (flag_isoc9x): Default off. (c_decode_option): Kill -std=gnu, add -std=gnu89 and -std=gnu9x. * cccp.c (print_help, main): Likewise. * gcc.c (default_compilers): Update for -std=gnu*. From-SVN: r24186
Diffstat (limited to 'gcc/c-decl.c')
-rw-r--r--gcc/c-decl.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c
index f5e9573..7e10ab4 100644
--- a/gcc/c-decl.c
+++ b/gcc/c-decl.c
@@ -470,7 +470,7 @@ int flag_traditional;
/* Nonzero means use the ISO C9x dialect of C. */
-int flag_isoc9x = 1;
+int flag_isoc9x = 0;
/* Nonzero means that we have builtin functions, and main is an int */
@@ -657,11 +657,12 @@ c_decode_option (argc, argv)
/* Select the appropriate language standard. We currently
recognize:
-std=iso9899:1990 same as -ansi
- -std=gnu default
-std=iso9899:199409 ISO C as modified in amend. 1
-std=iso9899:199x ISO C 9x
-std=c89 same as -std=iso9899:1990
-std=c9x same as -std=iso9899:199x
+ -std=gnu89 default, iso9899:1990 + gnu extensions
+ -std=gnu9x iso9899:199x + gnu extensions
*/
const char *argstart = &p[5];
@@ -689,7 +690,15 @@ c_decode_option (argc, argv)
flag_no_nonansi_builtin = 1;
flag_isoc9x = 1;
}
- else if (!strcmp (argstart, "gnu"))
+ else if (!strcmp (argstart, "gnu89"))
+ {
+ flag_traditional = 0;
+ flag_writable_strings = 0;
+ flag_no_asm = 0;
+ flag_no_nonansi_builtin = 0;
+ flag_isoc9x = 0;
+ }
+ else if (!strcmp (argstart, "gnu9x"))
{
flag_traditional = 0;
flag_writable_strings = 0;