Use dwarf_attr_integrate in various convenience functions.
authorRoland McGrath <roland@redhat.com>
Sat, 8 Aug 2009 01:26:19 +0000 (18:26 -0700)
committerRoland McGrath <roland@redhat.com>
Sat, 8 Aug 2009 01:27:36 +0000 (18:27 -0700)
NEWS
configure.ac
libdw/ChangeLog
libdw/dwarf_arrayorder.c
libdw/dwarf_bitoffset.c
libdw/dwarf_bitsize.c
libdw/dwarf_bytesize.c
libdw/dwarf_decl_file.c
libdw/dwarf_decl_line.c
libdw/dwarf_srclang.c

diff --git a/NEWS b/NEWS
index d52e253..4d08e2b 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,8 @@
+Version 0.143:
+
+libdw: Various convenience functions for individual attributes now use
+       dwarf_attr_integrate to look up indirect inherited attributes.
+
 Version 0.142:
 
 libelf: Add elf_getshdrnum alias for elf_getshnum and elf_getshdrstrndx alias
index 4d7ec1e..f5a3c52 100644 (file)
@@ -16,7 +16,7 @@ dnl You should have received a copy of the GNU General Public License
 dnl along with this program; if not, write to the Free Software Foundation,
 dnl Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
 dnl
-AC_INIT([Red Hat elfutils],[0.142],[http://bugzilla.redhat.com/bugzilla/],
+AC_INIT([Red Hat elfutils],[0.142.90],[http://bugzilla.redhat.com/bugzilla/],
        [elfutils])
 
 AC_CONFIG_AUX_DIR([config])
index 76663ee..30c8489 100644 (file)
@@ -1,3 +1,13 @@
+2009-08-07  Roland McGrath  <roland@redhat.com>
+
+       * dwarf_arrayorder.c: Use dwarf_attr_integrate.
+       * dwarf_srclang.c: Likewise.
+       * dwarf_decl_file.c: Likewise.
+       * dwarf_decl_line.c (__libdw_attr_intval): Likewise.
+       * dwarf_bytesize.c: Likewise.
+       * dwarf_bitsize.c: Likewise.
+       * dwarf_bitoffset.c: Likewise.
+
 2009-07-22  Roland McGrath  <roland@redhat.com>
 
        * dwarf_frame_cfa.c: Change calling convention.
index 6d5a42d..3593924 100644 (file)
@@ -1,5 +1,5 @@
 /* Return array order attribute of DIE.
-   Copyright (C) 2003, 2005 Red Hat, Inc.
+   Copyright (C) 2003, 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2003.
 
@@ -63,7 +63,7 @@ dwarf_arrayorder (die)
   Dwarf_Attribute attr_mem;
   Dwarf_Word value;
 
-  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr) (die, DW_AT_ordering,
-                                                     &attr_mem),
+  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr_integrate)
+                                 (die, DW_AT_ordering, &attr_mem),
                                  &value) == 0 ? (int) value : -1;
 }
index 235b7ee..99d1071 100644 (file)
@@ -1,5 +1,5 @@
 /* Return bit offset attribute of DIE.
-   Copyright (C) 2003, 2005 Red Hat, Inc.
+   Copyright (C) 2003, 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2003.
 
@@ -63,7 +63,7 @@ dwarf_bitoffset (die)
   Dwarf_Attribute attr_mem;
   Dwarf_Word value;
 
-  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr) (die, DW_AT_bit_offset,
-                                                     &attr_mem),
+  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr_integrate)
+                                 (die, DW_AT_bit_offset, &attr_mem),
                                  &value) == 0 ? (int) value : -1;
 }
index 57d7fba..7cfbc5d 100644 (file)
@@ -1,5 +1,5 @@
 /* Return bit size attribute of DIE.
-   Copyright (C) 2003, 2005 Red Hat, Inc.
+   Copyright (C) 2003, 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2003.
 
@@ -63,7 +63,7 @@ dwarf_bitsize (die)
   Dwarf_Attribute attr_mem;
   Dwarf_Word value;
 
-  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr) (die, DW_AT_bit_size,
-                                                     &attr_mem),
+  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr_integrate)
+                                 (die, DW_AT_bit_size, &attr_mem),
                                  &value) == 0 ? (int) value : -1;
 }
index 635a3c1..536fcd5 100644 (file)
@@ -1,5 +1,5 @@
 /* Return byte size attribute of DIE.
-   Copyright (C) 2003, 2005 Red Hat, Inc.
+   Copyright (C) 2003, 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2003.
 
@@ -63,7 +63,7 @@ dwarf_bytesize (die)
   Dwarf_Attribute attr_mem;
   Dwarf_Word value;
 
-  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr) (die, DW_AT_byte_size,
-                                                     &attr_mem),
+  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr_integrate)
+                                 (die, DW_AT_byte_size, &attr_mem),
                                  &value) == 0 ? (int) value : -1;
 }
index b1d62df..b5ea27d 100644 (file)
@@ -1,5 +1,5 @@
 /* Return file name containing definition of the given function.
-   Copyright (C) 2005 Red Hat, Inc.
+   Copyright (C) 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2005.
 
@@ -63,8 +63,9 @@ dwarf_decl_file (Dwarf_Die *die)
   Dwarf_Attribute attr_mem;
   Dwarf_Sword idx = 0;
 
-  if (INTUSE(dwarf_formsdata) (INTUSE(dwarf_attr) (die, DW_AT_decl_file,
-                                                  &attr_mem), &idx) != 0)
+  if (INTUSE(dwarf_formsdata) (INTUSE(dwarf_attr_integrate)
+                              (die, DW_AT_decl_file, &attr_mem),
+                              &idx) != 0)
     return NULL;
 
   /* Zero means no source file information available.  */
index b4e3c42..27abc50 100644 (file)
@@ -1,5 +1,5 @@
 /* Get line number of beginning of given function.
-   Copyright (C) 2005 Red Hat, Inc.
+   Copyright (C) 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2005.
 
@@ -71,8 +71,9 @@ __libdw_attr_intval (Dwarf_Die *die, int *linep, int attval)
   Dwarf_Attribute attr_mem;
   Dwarf_Sword line;
 
-  int res = INTUSE(dwarf_formsdata) (INTUSE(dwarf_attr) (die, attval,
-                                                        &attr_mem), &line);
+  int res = INTUSE(dwarf_formsdata) (INTUSE(dwarf_attr_integrate)
+                                    (die, attval, &attr_mem),
+                                    &line);
   if (res == 0)
     {
       assert (line >= 0 && line <= INT_MAX);
index 2efa095..7d0e907 100644 (file)
@@ -1,5 +1,5 @@
 /* Return source language attribute of DIE.
-   Copyright (C) 2003, 2005 Red Hat, Inc.
+   Copyright (C) 2003, 2005, 2009 Red Hat, Inc.
    This file is part of Red Hat elfutils.
    Written by Ulrich Drepper <drepper@redhat.com>, 2003.
 
@@ -63,7 +63,7 @@ dwarf_srclang (die)
   Dwarf_Attribute attr_mem;
   Dwarf_Word value;
 
-  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr) (die, DW_AT_language,
-                                                     &attr_mem),
+  return INTUSE(dwarf_formudata) (INTUSE(dwarf_attr_integrate)
+                                 (die, DW_AT_language, &attr_mem),
                                  &value) == 0 ? (int) value : -1;
 }