[Bug exp/12117] New: ptype can drop const/volatile information

dje at google dot com sourceware-bugzilla@sourceware.org
Wed Oct 13 17:20:00 GMT 2010


           Summary: ptype can drop const/volatile information
           Product: gdb
           Version: HEAD
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: exp
        AssignedTo: unassigned@sourceware.org
        ReportedBy: dje@google.com

Given this testcase:

typedef int my_int;
typedef const my_int const_my_int;
typedef volatile my_int volatile_my_int;
typedef volatile const_my_int volatile_const_my_int;
typedef const volatile_my_int const_volatile_my_int;

my_int v_my_int (0);
const_my_int v_const_my_int (1);
volatile_my_int v_volatile_my_int (2);
const_volatile_my_int v_const_volatile_my_int (3);
volatile_const_my_int v_volatile_const_my_int (4);

main ()
  return 0;

ptype will drop const/volatile information.

(gdb) ptype v_const_my_int
type = int
(gdb) ptype v_volatile_my_int
type = int
(gdb) ptype v_const_volatile_my_int
type = int

Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

More information about the Gdb-prs mailing list