OSDN Git Service

* c-decl.c (c_decode_option): Give deprecation warning for
authorjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 18 Nov 2001 17:16:24 +0000 (17:16 +0000)
committerjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 18 Nov 2001 17:16:24 +0000 (17:16 +0000)
-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.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@47147 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/c-decl.c
gcc/doc/invoke.texi
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/cpp/assert_trad1.c
gcc/testsuite/gcc.dg/cpp/tr-paste.c
gcc/testsuite/gcc.dg/cpp/tr-str.c
gcc/testsuite/gcc.dg/ext-glob.c

index b4ed1c4..dd33c36 100644 (file)
@@ -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
index 5a34a2c..4d7ca2b 100644 (file)
@@ -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;
     }
index 83e5c97..32a2b35 100644 (file)
@@ -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.
index 154d9c5..a4038a7 100644 (file)
@@ -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>
index 69f644b..6d3c04e 100644 (file)
@@ -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
index ac8a47b..e884e83 100644 (file)
@@ -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
 
index bc749ba..3423473 100644 (file)
@@ -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 ();
index cc772f5..deb51f5 100644 (file)
@@ -5,6 +5,7 @@
 
 /* { dg-do compile } */
 /* { dg-options -traditional } */
+/* { dg-warning "-traditional is deprecated" "deprecation warning" { target *-*-* } 0 } */
 
 int
 main ()