diff options
author | Joseph Myers <jsm28@cam.ac.uk> | 2001-11-18 17:16:24 +0000 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2001-11-18 17:16:24 +0000 |
commit | aa99bd097969b1be33198b73898b4f8a3021a837 (patch) | |
tree | 61e4108779bd37a598484824d53cc0b8054e6445 /gcc | |
parent | 6f4fdd10f3563b9b04c4491c6a55608b1d975651 (diff) | |
download | gcc-aa99bd097969b1be33198b73898b4f8a3021a837.zip gcc-aa99bd097969b1be33198b73898b4f8a3021a837.tar.gz gcc-aa99bd097969b1be33198b73898b4f8a3021a837.tar.bz2 |
c-decl.c (c_decode_option): Give deprecation warning for -traditional.
* c-decl.c (c_decode_option): Give deprecation warning for
-traditional.
* doc/invoke.texi (-traditional): Note that this option is
deprecated.
testsuite:
* gcc.dg/cpp/assert_trad1.c, gcc.dg/cpp/tr-paste.c,
gcc.dg/cpp/tr-str.c: Use -traditional-cpp instead of -traditional.
* gcc.dg/ext-glob.c: Expect -traditional deprecation warning.
From-SVN: r47147
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/c-decl.c | 1 | ||||
-rw-r--r-- | gcc/doc/invoke.texi | 2 | ||||
-rw-r--r-- | gcc/testsuite/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/cpp/assert_trad1.c | 2 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/cpp/tr-paste.c | 2 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/cpp/tr-str.c | 2 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/ext-glob.c | 1 |
8 files changed, 20 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index b4ed1c4..dd33c36 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2001-11-18 Joseph S. Myers <jsm28@cam.ac.uk> + + * c-decl.c (c_decode_option): Give deprecation warning for + -traditional. + * doc/invoke.texi (-traditional): Note that this option is + deprecated. + Sun Nov 18 07:40:07 2001 Douglas B. Rupp <rupp@gnat.com> * config/alpha/alpha.c (alpha_start_function, VMS): Cast shift diff --git a/gcc/c-decl.c b/gcc/c-decl.c index 5a34a2c..4d7ca2b 100644 --- a/gcc/c-decl.c +++ b/gcc/c-decl.c @@ -457,6 +457,7 @@ c_decode_option (argc, argv) if (!strcmp (p, "-ftraditional") || !strcmp (p, "-traditional")) { + warning ("-traditional is deprecated and may be removed"); flag_traditional = 1; flag_writable_strings = 1; } diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 83e5c97..32a2b35 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -1147,6 +1147,8 @@ literal characters @samp{x} and @samp{a} respectively. Without representation of a character, and @samp{\a} produces a bell. @end itemize +This option is deprecated and may be removed. + You may wish to use @option{-fno-builtin} as well as @option{-traditional} if your program uses names that are normally GNU C built-in functions for other purposes of its own. diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 154d9c5..a4038a7 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,5 +1,11 @@ 2001-11-18 Joseph S. Myers <jsm28@cam.ac.uk> + * gcc.dg/cpp/assert_trad1.c, gcc.dg/cpp/tr-paste.c, + gcc.dg/cpp/tr-str.c: Use -traditional-cpp instead of -traditional. + * gcc.dg/ext-glob.c: Expect -traditional deprecation warning. + +2001-11-18 Joseph S. Myers <jsm28@cam.ac.uk> + * gcc.dg/no-builtin-1.c: New test. 2001-11-16 Jakub Jelinek <jakub@redhat.com> diff --git a/gcc/testsuite/gcc.dg/cpp/assert_trad1.c b/gcc/testsuite/gcc.dg/cpp/assert_trad1.c index 69f644b..6d3c04e 100644 --- a/gcc/testsuite/gcc.dg/cpp/assert_trad1.c +++ b/gcc/testsuite/gcc.dg/cpp/assert_trad1.c @@ -1,6 +1,6 @@ /* Basic tests of the #assert preprocessor extension. */ /* { dg-do compile } */ -/* { dg-options "-traditional" } */ +/* { dg-options "-traditional-cpp" } */ /* #define def unused expansion */ /* tradcpp can't handle macros in answers. */ #define fail int failit diff --git a/gcc/testsuite/gcc.dg/cpp/tr-paste.c b/gcc/testsuite/gcc.dg/cpp/tr-paste.c index ac8a47b..e884e83 100644 --- a/gcc/testsuite/gcc.dg/cpp/tr-paste.c +++ b/gcc/testsuite/gcc.dg/cpp/tr-paste.c @@ -3,7 +3,7 @@ Test case by Jason R. Thorpe <thorpej@zembu.com>. */ /* { dg-do compile } */ -/* { dg-options "-traditional" } */ +/* { dg-options "-traditional-cpp" } */ #define A(name) X/**/name diff --git a/gcc/testsuite/gcc.dg/cpp/tr-str.c b/gcc/testsuite/gcc.dg/cpp/tr-str.c index bc749ba..3423473 100644 --- a/gcc/testsuite/gcc.dg/cpp/tr-str.c +++ b/gcc/testsuite/gcc.dg/cpp/tr-str.c @@ -1,6 +1,6 @@ /* Test whether traditional stringify works. */ /* { dg-do run } */ -/* { dg-options "-traditional" } */ +/* { dg-options "-traditional-cpp" } */ #define foo(a, b) c="a"; d="b"; extern void abort (); diff --git a/gcc/testsuite/gcc.dg/ext-glob.c b/gcc/testsuite/gcc.dg/ext-glob.c index cc772f5..deb51f5 100644 --- a/gcc/testsuite/gcc.dg/ext-glob.c +++ b/gcc/testsuite/gcc.dg/ext-glob.c @@ -5,6 +5,7 @@ /* { dg-do compile } */ /* { dg-options -traditional } */ +/* { dg-warning "-traditional is deprecated" "deprecation warning" { target *-*-* } 0 } */ int main () |