public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/15111] New: GDB will not print the value of a variable if there exists a type of the same name
@ 2013-02-06 21:06 mgretton at sourceware dot org
2013-02-06 21:08 ` [Bug c++/15111] " mgretton at sourceware dot org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: mgretton at sourceware dot org @ 2013-02-06 21:06 UTC (permalink / raw)
To: gdb-prs
http://sourceware.org/bugzilla/show_bug.cgi?id=15111
Bug #: 15111
Summary: GDB will not print the value of a variable if there
exists a type of the same name
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned@sourceware.org
ReportedBy: mgretton@sourceware.org
Classification: Unclassified
Created attachment 6850
--> http://sourceware.org/bugzilla/attachment.cgi?id=6850
Source for test case
Given the attached gdb-test.cpp file compiled as follows:
$ g++ -O2 -g gdb-test.cpp -o gdb-test
This program has a structure named fibs and a global variable also named fibs.
When you use gdb (as follows) you cannot get to the value of the global
variable because GDB seems to only see the typename:
$ gdb ./gdb-test
(gdb) start
...
(gdb) print fibs
Attempt to use a typename as an expression
(This is the instance of that error from gdb/expr.c)
The .debug_info section seems to be correct (objdump --dwarf=info output also
attached).
--
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.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/15111] GDB will not print the value of a variable if there exists a type of the same name
2013-02-06 21:06 [Bug c++/15111] New: GDB will not print the value of a variable if there exists a type of the same name mgretton at sourceware dot org
@ 2013-02-06 21:08 ` mgretton at sourceware dot org
2013-03-20 15:26 ` dje at google dot com
2013-07-30 6:34 ` b.r.longbons at gmail dot com
2 siblings, 0 replies; 4+ messages in thread
From: mgretton at sourceware dot org @ 2013-02-06 21:08 UTC (permalink / raw)
To: gdb-prs
http://sourceware.org/bugzilla/show_bug.cgi?id=15111
--- Comment #1 from Matthew Gretton-Dann <mgretton at sourceware dot org> 2013-02-06 21:08:16 UTC ---
Created attachment 6851
--> http://sourceware.org/bugzilla/attachment.cgi?id=6851
DWARF .debug_info section produced by GCC for the test case.
--
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.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/15111] GDB will not print the value of a variable if there exists a type of the same name
2013-02-06 21:06 [Bug c++/15111] New: GDB will not print the value of a variable if there exists a type of the same name mgretton at sourceware dot org
2013-02-06 21:08 ` [Bug c++/15111] " mgretton at sourceware dot org
@ 2013-03-20 15:26 ` dje at google dot com
2013-07-30 6:34 ` b.r.longbons at gmail dot com
2 siblings, 0 replies; 4+ messages in thread
From: dje at google dot com @ 2013-03-20 15:26 UTC (permalink / raw)
To: gdb-prs
http://sourceware.org/bugzilla/show_bug.cgi?id=15111
dje at google dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dje at google dot com
See Also| |http://sourceware.org/bugzi
| |lla/show_bug.cgi?id=15288
--
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.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/15111] GDB will not print the value of a variable if there exists a type of the same name
2013-02-06 21:06 [Bug c++/15111] New: GDB will not print the value of a variable if there exists a type of the same name mgretton at sourceware dot org
2013-02-06 21:08 ` [Bug c++/15111] " mgretton at sourceware dot org
2013-03-20 15:26 ` dje at google dot com
@ 2013-07-30 6:34 ` b.r.longbons at gmail dot com
2 siblings, 0 replies; 4+ messages in thread
From: b.r.longbons at gmail dot com @ 2013-07-30 6:34 UTC (permalink / raw)
To: gdb-prs
http://sourceware.org/bugzilla/show_bug.cgi?id=15111
Ben Longbons <b.r.longbons at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
CC| |b.r.longbons at gmail dot com
Resolution|--- |DUPLICATE
--- Comment #2 from Ben Longbons <b.r.longbons at gmail dot com> ---
bugzilla requires a message when marking a duplicate
*** This bug has been marked as a duplicate of bug 7737 ***
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-07-30 6:34 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-06 21:06 [Bug c++/15111] New: GDB will not print the value of a variable if there exists a type of the same name mgretton at sourceware dot org
2013-02-06 21:08 ` [Bug c++/15111] " mgretton at sourceware dot org
2013-03-20 15:26 ` dje at google dot com
2013-07-30 6:34 ` b.r.longbons at gmail dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).