[LLVMbugs] [Bug 24269] New: [debug info] Template parameter packs - incorrect arguments in appear in gdb
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sun Jul 26 16:29:26 PDT 2015
https://llvm.org/bugs/show_bug.cgi?id=24269
Bug ID: 24269
Summary: [debug info] Template parameter packs - incorrect
arguments in appear in gdb
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++11
Assignee: unassignedclangbugs at nondot.org
Reporter: hfinkel at anl.gov
CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
Classification: Unclassified
$ cat /tmp/d2.cpp
#include <iostream>
using namespace std;
template <typename ... T>
void foo(T ... t) {
cout << "here\n";
}
int main() {
foo(3, 3, 5, 6);
}
$ clang++ -std=c++14 -g -o ~/tmp/d /tmp/d2.cpp
$ gdb ~/tmp/d
GNU gdb (GDB) 7.7
...
Reading symbols from ~/tmp/d...done.
(gdb) b main
Breakpoint 1 at 0x4007a3: file /tmp/d2.cpp, line 10.
(gdb) s
The program is not being run.
(gdb) r
Starting program: ~/tmp/d
Breakpoint 1, main () at /tmp/d2.cpp:10
10 foo(3, 3, 5, 6);
(gdb) s
foo<int, int, int, int> (t=6, t=6, t=6, t=6) at /tmp/d2.cpp:6
6 cout << "here\n";
(gdb) p t
$1 = 6
(gdb) quit
The '(t=6, t=6, t=6, t=6)' bit is clearly wrong. This obviously might be a gdb
bug; I don't know how to tell. FWIW, MS Visual Studio produces
pseudo-parameters t_0, t_1, etc. Perhaps that would be better?
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150726/ef8ea001/attachment.html>
More information about the llvm-bugs
mailing list