From 2a9d769a7f82fb505b88cb590690885e937e5662 Mon Sep 17 00:00:00 2001 From: Olivier Hainque Date: Fri, 1 Apr 2011 23:38:57 +0000 Subject: dwarf2out.c (dwarf_attr_name): Map DW_AT_GNAT_descriptive_type. * dwarf2out.c (dwarf_attr_name): Map DW_AT_GNAT_descriptive_type. (add_gnat_descriptive_type_attribute): New function. (gen_array_type_die): Call it. (gen_enumeration_type_die): Likewise. (gen_struct_or_union_type_die): Likewise. (modified_type_die): Likewise. * langhooks.h (lang_hooks_for_types): New descriptive_type hook. * langhooks-def.h (LANG_HOOKS_DESCRIPTIVE_TYPE): Default to NULL. (LANG_HOOKS_FOR_TYPES_INITIALIZER): Add LANG_HOOKS_DESCRIPTIVE_TYPE. ada/ * gcc-interface/misc.c (gnat_descriptive_type): New function. (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type. Co-Authored-By: Eric Botcazou Co-Authored-By: Nicolas Setton From-SVN: r171862 --- gcc/langhooks.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'gcc/langhooks.h') diff --git a/gcc/langhooks.h b/gcc/langhooks.h index a9947293e91..e0dea01fc9a 100644 --- a/gcc/langhooks.h +++ b/gcc/langhooks.h @@ -1,6 +1,6 @@ /* The lang_hooks data structure. - Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 - Free Software Foundation, Inc. + Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, + 2011 Free Software Foundation, Inc. This file is part of GCC. @@ -132,6 +132,11 @@ struct lang_hooks_for_types /* Fill in information for the debugger about the bounds of TYPE. */ void (*get_subrange_bounds) (const_tree, tree *, tree *); + /* A type descriptive of TYPE's complex layout generated to help the + debugger to decode variable-length or self-referential constructs. + This is only used for the AT_GNAT_descriptive_type DWARF attribute. */ + tree (*descriptive_type) (const_tree); + /* If we requested a pointer to a vector, build up the pointers that we stripped off while looking for the inner type. Similarly for return values from functions. The argument TYPE is the top of the -- cgit v1.2.1