]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
cpplib.h (cpp_options): Use signed char.
authorMarek Polacek <polacek@redhat.com>
Wed, 20 Aug 2014 04:12:58 +0000 (04:12 +0000)
committerMarek Polacek <mpolacek@gcc.gnu.org>
Wed, 20 Aug 2014 04:12:58 +0000 (04:12 +0000)
* include/cpplib.h (cpp_options): Use signed char.
* lex.c (_cpp_lex_direct): Don't warn in C++ mode.

From-SVN: r214210

libcpp/ChangeLog
libcpp/include/cpplib.h
libcpp/lex.c

index 6b8fe2835a3a3ccb62e98643064b859ced05bbd7..89c840658f0a0102eb7559882ee8996b83e9dfa4 100644 (file)
@@ -1,3 +1,8 @@
+2014-08-20  Marek Polacek  <polacek@redhat.com>
+
+       * include/cpplib.h (cpp_options): Use signed char.
+       * lex.c (_cpp_lex_direct): Don't warn in C++ mode.
+
 2014-08-19  Marek Polacek  <polacek@redhat.com>
 
        * lex.c (_cpp_lex_direct): Fix a typo.
index b89ba200699039bb076aa0ce7ad93ef259f76381..9f87ff8b514f67025bc13cc6488b48aa65446ef1 100644 (file)
@@ -467,7 +467,7 @@ struct cpp_options
   bool restore_pch_deps;
 
   /* True if warn about differences between C90 and C99.  */
-  char cpp_warn_c90_c99_compat;
+  signed char cpp_warn_c90_c99_compat;
 
   /* Dependency generation.  */
   struct
index 827cfb0d75f304fe1471933e142190a4bd2fbf7a..5366dad9e44f1dfa5918d6680d08ca6a3c54417c 100644 (file)
@@ -2338,6 +2338,7 @@ _cpp_lex_direct (cpp_reader *pfile)
            }
          /* Or if specifically desired via -Wc90-c99-compat.  */
          else if (CPP_OPTION (pfile, cpp_warn_c90_c99_compat) > 0
+                  && ! CPP_OPTION (pfile, cplusplus)
                   && ! buffer->warned_cplusplus_comments)
            {
              cpp_error (pfile, CPP_DL_WARNING,