This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug python/11874] New: Vector pretty-printer chokes on bit-vectors
- From: "ppluzhnikov at google dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: 3 Aug 2010 20:40:54 -0000
- Subject: [Bug python/11874] New: Vector pretty-printer chokes on bit-vectors
- Reply-to: sourceware-bugzilla at sourceware dot org
Test case:
// --- cut --- bitvector.cc ---
#include <vector>
typedef std::vector<bool> BV;
int main()
{
BV bv;
bv.push_back(true);
return 0;
}
// --- cut --- bitvector.cc ---
Using gcc 4.6.0 20100803 (experimental):
g++ -g bitvector.cc
gdb ./a.out
GNU gdb (GDB) 7.2.50.20100731-cvs
...
(gdb) python
>sys.path.insert(0, '/home/gcc-svn-install/share/gcc-4.6.0/python')
>from libstdcxx.v6.printers import register_libstdcxx_printers
>register_libstdcxx_printers (None)
^D
(gdb) b main
Breakpoint 1 at 0x4007fd: file bitvector.cc, line 7.
(gdb) r
Breakpoint 1, main () at bitvector.cc:7
7 BV bv;
(gdb) n
8 bv.push_back(true);
(gdb) p bv
$1 = Traceback (most recent call last):
File "/home/gcc-svn-install/share/gcc-4.6.0/python/libstdcxx/v6/printers.py",
line 186, in to_string
% (self.typename, int (finish - start), int (end - start)))
RuntimeError: Argument to arithmetic operation not a number or boolean.
Traceback (most recent call last):
File "/home/gcc-svn-install/share/gcc-4.6.0/python/libstdcxx/v6/printers.py",
line 169, in next
elt = self.item.dereference()
RuntimeError: Attempt to take contents of a non-pointer value.
--
Summary: Vector pretty-printer chokes on bit-vectors
Product: gdb
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: python
AssignedTo: unassigned at sourceware dot org
ReportedBy: ppluzhnikov at google dot com
CC: gdb-prs at sourceware dot org
GCC build triplet: x86_64-unknown-linux-gnu
GCC host triplet: x86_64-unknown-linux-gnu
GCC target triplet: x86_64-unknown-linux-gnu
http://sourceware.org/bugzilla/show_bug.cgi?id=11874
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.