* dwarf2read.c (read_enumeration_type): Flag type as stub if
authorJoel Brobecker <brobecker@gnat.com>
Thu, 3 Jan 2008 17:29:56 +0000 (17:29 +0000)
committerJoel Brobecker <brobecker@gnat.com>
Thu, 3 Jan 2008 17:29:56 +0000 (17:29 +0000)
        the given die is a declaration.

gdb/ChangeLog
gdb/dwarf2read.c

index 0a9e63c21e5dee4bb33908798abf7716c81fc750..96fcd9babbe30e2d75cdff68280e4dd3efc19dce 100644 (file)
@@ -1,3 +1,8 @@
+2008-01-03  Joel Brobecker  <brobecker@adacore.com>
+
+       * dwarf2read.c (read_enumeration_type): Flag type as stub if
+       the given die is a declaration.
+
 2008-01-03  Joel Brobecker  <brobecker@adacore.com>
 
        * ada-lang.c (ada_array_bound_from_type): Make non-static.
index a40db748c69cad0884d4d9f8b28f15383f8aae85..f9dfff1959229f9916cb5ca8ed1bd2fa9659954b 100644 (file)
@@ -4233,6 +4233,9 @@ read_enumeration_type (struct die_info *die, struct dwarf2_cu *cu)
       TYPE_LENGTH (type) = 0;
     }
 
+  if (die_is_declaration (die, cu))
+    TYPE_FLAGS (type) |= TYPE_FLAG_STUB;
+
   set_die_type (die, type, cu);
 }