This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[cs] some c-opts.c simplification


I checked the attached patch into the compile-server
branch.
--
	--Per Bothner
per@bothner.com   http://per.bothner.com/

2003-08-21  Per Bothner  <pbothner@apple.com>

	* c-opts.c (init_c_common_once):  Do finish_options now,
	regardless of server_mode.
	(c_common_parse_file):  Never do finish_options now.

	* c-opts.c (push_command_line_include):  Don't do cpp_change_file.

Index: c-opts.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/c-opts.c,v
retrieving revision 1.79.2.3
diff -u -p -r1.79.2.3 c-opts.c
--- c-opts.c	15 Aug 2003 21:47:03 -0000	1.79.2.3
+++ c-opts.c	21 Aug 2003 19:40:22 -0000
@@ -1160,8 +1160,7 @@ init_c_common_once ()
   if (warn_missing_format_attribute && !warn_format)
     warning ("-Wmissing-format-attribute ignored without -Wformat");
 
-  if (server_mode >= 0)
-    finish_options ();
+  finish_options ();
 #if 0
   if (flag_preprocess_onl
       && num_in_fnames > 1)
@@ -1192,9 +1191,6 @@ c_common_parse_file (int set_yydebug ATT
 #endif
 
   (*debug_hooks->start_source_file) (input_line, input_filename);
-  /* Kludge - finish_options emits debug stuff, so needs assembler. */
-  if (server_mode < 0)
-    finish_options ();
 
   c_parse_file ();
   free_parser_stacks ();
@@ -1435,8 +1431,6 @@ push_command_line_include (void)
 
   if (include_cursor == deferred_count)
     {
-      /* Restore the line map from <command line>.  */
-      cpp_change_file (parse_in, LC_RENAME, main_input_filename);
       /* -Wunused-macros should only warn about macros defined hereafter.  */
       cpp_opts->warn_unused_macros = warn_unused_macros;
       include_cursor++;

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]