* buildsym.c (start_subfile): Set language for f2c like for cfront.
authorJim Kingdon <jkingdon@engr.sgi.com>
Sun, 12 Feb 1995 17:53:34 +0000 (17:53 +0000)
committerJim Kingdon <jkingdon@engr.sgi.com>
Sun, 12 Feb 1995 17:53:34 +0000 (17:53 +0000)
gdb/ChangeLog
gdb/buildsym.c

index fb03eae9d01102430c8189c5f3da9eb7b8d93b7f..9ac6b299a41ed295cd7577bef7ffdc1b0a19d746 100644 (file)
@@ -1,3 +1,11 @@
+Sun Feb 12 09:03:47 1995  Jim Kingdon  (kingdon@lioth.cygnus.com)
+
+       * buildsym.c (start_subfile): Set language for f2c like for cfront.
+
+Thu Feb  9 20:20:11 1995  Rob Savoye  <rob@darkstar.cygnus.com>
+
+       * op50n-rom.c: Add the control registers.
+
 Thu Feb  9 15:46:39 1995  Stan Shebs  <shebs@andros.cygnus.com>
 
        * Makefile.in (CLIBS): Add $(LIBIBERTY) before, in addition to
index e4dcbddc568707d6fe3defd55ab3ce7b8f531775..fc03378844735fa163ccf4b1b46c654155f30da8 100644 (file)
@@ -439,23 +439,26 @@ start_subfile (name, dirname)
      of any pending subfiles from C to C++.  We also accept any other C++
      suffixes accepted by deduce_language_from_filename (in particular,
      some people use .cxx with cfront).  */
+  /* Likewise for f2c.  */
 
   if (subfile->name)
     {
       struct subfile *s;
+      enum language sublang = deduce_language_from_filename (subfile->name);
 
-      if (deduce_language_from_filename (subfile->name) == language_cplus)
+      if (sublang == language_cplus || sublang == language_fortran)
        for (s = subfiles; s != NULL; s = s->next)
          if (s->language == language_c)
-           s->language = language_cplus;
+           s->language = sublang;
     }
 
   /* And patch up this file if necessary.  */
   if (subfile->language == language_c
       && subfile->next != NULL
-      && subfile->next->language == language_cplus)
+      && (subfile->next->language == language_cplus
+         || subfile->next->language == language_fortran))
     {
-      subfile->language = language_cplus;
+      subfile->language = subfile->next->language;
     }
 }