This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug python/20590] New: gdb.Type.template_argument cannot handle local types in variadic packs
- From: "lucdanton at free dot fr" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 09 Sep 2016 05:39:25 +0000
- Subject: [Bug python/20590] New: gdb.Type.template_argument cannot handle local types in variadic packs
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=20590
Bug ID: 20590
Summary: gdb.Type.template_argument cannot handle local types
in variadic packs
Product: gdb
Version: 7.11.1
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: python
Assignee: unassigned at sourceware dot org
Reporter: lucdanton at free dot fr
Target Milestone: ---
On 7.11.1:
//------
template<typename X> struct non_variadic {};
template<typename... Xs> struct variadic {};
int main()
{
struct local {};
non_variadic<local> nv;
variadic<local> v;
}
//-----
The above is compiled as g++ -std=c++11 -g main.cpp, then when debugging:
$ gdb a.out
GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.04) 7.11.1
Copyright (C) 2016 Free Software Foundation, Inc.
[..snip..]
(gdb) b main
Breakpoint 1 at 0x4004da: file main.cpp, line 9.
(gdb) r
Starting program: /home/lucdanton/test/a.out
Breakpoint 1, main () at main.cpp:9
9 }
(gdb) p nv
$1 = {<No data fields>}
(gdb) p v
$2 = {<No data fields>}
(gdb) py x = gdb.history(1)
(gdb) py y = gdb.history(2)
(gdb) py print(x.type.template_argument(0))
local
(gdb) py print(y.type.template_argument(0))
Traceback (most recent call last):
File "<string>", line 1, in <module>
RuntimeError: syntax error, near `)::local>'
Error while executing Python code.
--
You are receiving this mail because:
You are on the CC list for the bug.