OSDN Git Service

PR debug/10055
authorneil <neil@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 7 Jul 2003 05:02:22 +0000 (05:02 +0000)
committerneil <neil@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 7 Jul 2003 05:02:22 +0000 (05:02 +0000)
* lex.c (cxx_init): Call push_srcloc and pop_srcloc rather than
assigning to input_filename directly.

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

gcc/cp/ChangeLog
gcc/cp/lex.c

index dd27135..3539a06 100644 (file)
@@ -1,3 +1,9 @@
+2003-07-06  Michael Chastain  <mec@shout.net>
+
+       PR debug/10055
+       * lex.c (cxx_init): Call push_srcloc and pop_srcloc rather than
+       assigning to input_filename directly.
+
 2003-07-06  Kazu Hirata  <kazu@cs.umass.edu>
 
        * call.c: Fix comment formatting.
index a3f2878..7d63e2c 100644 (file)
@@ -392,7 +392,10 @@ cxx_init (void)
 
   INIT_STATEMENT_CODES (stmt_codes);
 
-  input_filename = "<internal>";
+  /* We cannot just assign to input_filename because it has already
+     been initialized and will be used later as an N_BINCL for stabs+
+     debugging.  */
+  push_srcloc ("<internal>", 0);
 
   init_reswords ();
   init_tree ();
@@ -429,12 +432,16 @@ cxx_init (void)
   interface_unknown = 1;
 
   if (c_common_init () == false)
-    return false;
+    {
+      pop_srcloc();
+      return false;
+    }
 
   init_cp_pragma ();
 
   init_repo (main_input_filename);
 
+  pop_srcloc();
   return true;
 }
 \f