re PR preprocessor/17651 (Erroneous preprocessor output with -g when generating depen...
authorNathanael Nerode <neroden@gcc.gnu.org>
Sun, 28 Nov 2004 23:29:41 +0000 (23:29 +0000)
committerNathanael Nerode <neroden@gcc.gnu.org>
Sun, 28 Nov 2004 23:29:41 +0000 (23:29 +0000)
2004-11-28  Nathanael Nerode  <neroden@gcc.gnu.org>

PR preprocessor/17651
* c-opts.c (sanitize_cpp_opts): Make flag_no_output imply
flag_no_line_commands.
* c-ppoutput.c (pp_file_change): Remove now-redundant check of
flag_no_output.

From-SVN: r91436

gcc/c-opts.c
gcc/c-ppoutput.c

index 8eef6bfbf0077042975e555598818ffd267d3027..a0bc0f6c01057dea9ac22cebe4e3e6e1e8c13bca 100644 (file)
@@ -1222,11 +1222,13 @@ sanitize_cpp_opts (void)
 
   /* Disable -dD, -dN and -dI if normal output is suppressed.  Allow
      -dM since at least glibc relies on -M -dM to work.  */
+  /* Also, flag_no_output implies flag_no_line_commands, always. */
   if (flag_no_output)
     {
       if (flag_dump_macros != 'M')
        flag_dump_macros = 0;
       flag_dump_includes = 0;
+      flag_no_line_commands = 1;
     }
 
   cpp_opts->unsigned_char = !flag_signed_char;
index 64b27a75f62135826cbb17484bf96f4acc6929df..996c5f0253443303f623b07996c2dc6ac21c8d69 100644 (file)
@@ -370,7 +370,7 @@ pp_file_change (const struct line_map *map)
 {
   const char *flags = "";
 
-  if (flag_no_line_commands || flag_no_output)
+  if (flag_no_line_commands)
     return;
 
   if (map != NULL)