* config/obj-aout.h: Fix comment typos.
[deliverable/binutils-gdb.git] / gdb / dwarfread.c
index 0856b899dc54eb7b1e9bd6097d0cca783ca20c29..5c1848707ab63d4f9ebcf7aa88c0c07d58d5e25a 100644 (file)
@@ -979,6 +979,13 @@ struct_type (struct dieinfo *dip, char *thisdie, char *enddie,
       switch (mbr.die_tag)
        {
        case TAG_member:
+         /* Static fields can be either TAG_global_variable (GCC) or else
+            TAG_member with no location (Diab).  We could treat the latter like
+            the former... but since we don't support the former, just avoid
+            crashing on the latter for now.  */
+         if (mbr.at_location == NULL)
+           break;
+
          /* Get space to record the next field's data.  */
          new = (struct nextfield *) alloca (sizeof (struct nextfield));
          new->next = list;
@@ -1803,7 +1810,7 @@ handle_producer (char *producer)
   else
     {
       processing_gcc_compilation =
-       STREQN (producer, GPLUS_PRODUCER, strlen (GPLUS_PRODUCER));
+       strncmp (producer, GPLUS_PRODUCER, strlen (GPLUS_PRODUCER)) == 0;
     }
 
   /* Select a demangling style if we can identify the producer and if
@@ -1861,8 +1868,8 @@ read_file_scope (struct dieinfo *dip, char *thisdie, char *enddie,
   if (objfile->ei.entry_point >= dip->at_low_pc &&
       objfile->ei.entry_point < dip->at_high_pc)
     {
-      objfile->ei.entry_file_lowpc = dip->at_low_pc;
-      objfile->ei.entry_file_highpc = dip->at_high_pc;
+      objfile->ei.deprecated_entry_file_lowpc = dip->at_low_pc;
+      objfile->ei.deprecated_entry_file_highpc = dip->at_high_pc;
     }
   set_cu_language (dip);
   if (dip->at_producer != NULL)
@@ -3191,8 +3198,12 @@ decode_modified_type (char *modifiers, unsigned int modcount, int mtype)
                     DIE_ID, DIE_NAME); /* FIXME */
          break;
        default:
-         if (!(MOD_lo_user <= (unsigned char) modifier
+         if (!(MOD_lo_user <= (unsigned char) modifier))
+#if 0
+/* This part of the test would always be true, and it triggers a compiler
+   warning.  */
                && (unsigned char) modifier <= MOD_hi_user))
+#endif
            {
              complaint (&symfile_complaints,
                         "DIE @ 0x%x \"%s\", unknown type modifier %u", DIE_ID,
This page took 0.023582 seconds and 4 git commands to generate.