This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gdb and binutils branch master updated. 5ec18f2b48ab74bbbaf436324ce3947df3bc048e


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".

The branch, master has been updated
       via  5ec18f2b48ab74bbbaf436324ce3947df3bc048e (commit)
      from  7d03f2eb64305b386f2ae8b733e0a2a143fd4ffd (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=5ec18f2b48ab74bbbaf436324ce3947df3bc048e

commit 5ec18f2b48ab74bbbaf436324ce3947df3bc048e
Author: Jerome Guitton <guitton@adacore.com>
Date:   Wed Feb 12 12:08:23 2014 +0100

    [Ada] Full view of tagged type with ptype
    
    When evaluating an expression, if it is of a tagged type, GDB reads
    the tag in memory and deduces the full view. At parsing time, however,
    this operation is done only in the case of OP_VAR_VALUE. ptype does
    not go through a full evaluation of expressions so it may return some
    odd results:
    
     (gdb) print c.menu_name
     $1 = 0x0
     (gdb) ptype $
     type = system.strings.string_access
     (gdb) ptype c.menu_name
     type = <void>
    
    This change removes this peculiarity by extending the tag resolution
    to UNOP_IND and STRUCTOP_STRUCT. As in the case of OP_VAR_VALUE, this
    implies switching from EVAL_AVOID_SIDE_EFFECTS to EVAL_NORMAL when a
    tagged type is dereferenced.
    
    gdb/
    	* ada-lang.c (ada_evaluate_subexp): Resolve tagged types to
    	full view in the case of UNOP_IND and STRUCTOP_STRUCT.
    
    gdb/testsuite/
    
    	* gdb.ada/tagged_access: New testcase.

-----------------------------------------------------------------------

Summary of changes:
 gdb/ChangeLog                                |    5 +++
 gdb/ada-lang.c                               |   47 ++++++++++++++++++++-----
 gdb/testsuite/ChangeLog                      |    4 ++
 gdb/testsuite/gdb.ada/tagged_access.exp      |   33 ++++++++++++++++++
 gdb/testsuite/gdb.ada/tagged_access/p.adb    |   22 ++++++++++++
 gdb/testsuite/gdb.ada/tagged_access/pack.adb |   30 ++++++++++++++++
 gdb/testsuite/gdb.ada/tagged_access/pack.ads |   31 +++++++++++++++++
 7 files changed, 162 insertions(+), 10 deletions(-)
 create mode 100644 gdb/testsuite/gdb.ada/tagged_access.exp
 create mode 100644 gdb/testsuite/gdb.ada/tagged_access/p.adb
 create mode 100644 gdb/testsuite/gdb.ada/tagged_access/pack.adb
 create mode 100644 gdb/testsuite/gdb.ada/tagged_access/pack.ads


hooks/post-receive
-- 
gdb and binutils


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]