handle DW_AT_type on an enumeration
authorTom Tromey <tromey@redhat.com>
Wed, 26 Mar 2014 14:54:56 +0000 (08:54 -0600)
committerTom Tromey <tromey@redhat.com>
Mon, 14 Apr 2014 17:42:17 +0000 (11:42 -0600)
commit0626fc76d1b95c1c5b158a9b0be17791aa9078f8
treed791c48f8f03f596ea5ff05c0c1978fa580a4a61
parentdca325b370730f8cfd3b63ac848569bf58d8746c
handle DW_AT_type on an enumeration

DWARF allows an enumeration type to have a DW_AT_type.  GDB doesn't
recognize this, but there is a patch to change GCC to emit it, and a
DWARF proposal to further allow an enum type with a DW_AT_type to omit
the DW_AT_byte_size.  This patch changes gdb to implement this.

Built and regtested on x86-64 Fedora 20.

2014-04-14  Tom Tromey  <tromey@redhat.com>

* dwarf2read.c (read_enumeration_type): Handle DW_AT_type.

2014-04-14  Tom Tromey  <tromey@redhat.com>

* gdb.dwarf2/enum-type.exp: New file.
gdb/ChangeLog
gdb/dwarf2read.c
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.dwarf2/enum-type.exp [new file with mode: 0644]