[LLVMbugs] [Bug 7178] New: Crash on invalid extra typename
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Thu May 20 03:23:01 PDT 2010
http://llvm.org/bugs/show_bug.cgi?id=7178
Summary: Crash on invalid extra typename
Product: clang
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: abramobagnara at tin.it
CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com
$ cat bug.cc
template <typename T>
struct v { };
template <typename T>
struct s {
typedef typename v<T> a;
};
s<int>::a x;
$ ~/llvm_new/Debug/bin/clang++ -cc1 bug.cc
bug.cc:6:19: error: expected a qualified name after 'typename'
typedef typename v<T> a;
^
clang++: SemaDecl.cpp:4866: clang::TypedefDecl*
clang::Sema::ParseTypedefDecl(clang::Scope*, clang::Declarator&,
clang::QualType, clang::TypeSourceInfo*): Assertion `D.getIdentifier() &&
"Wrong callback for declspec without declarator"' failed.
0 clang++ 0x000000000139dcd5
1 clang++ 0x000000000139e1c0
2 libpthread.so.0 0x00000036aa80f0f0
3 libc.so.6 0x00000036a9c32f05 gsignal + 53
4 libc.so.6 0x00000036a9c34a73 abort + 387
5 libc.so.6 0x00000036a9c2bef9 __assert_fail + 233
6 clang++ 0x00000000006ba405
7 clang++ 0x00000000006c9b0f
8 clang++ 0x00000000006cd44d
9 clang++ 0x00000000006f836f
10 clang++ 0x0000000000a1c79f
11 clang++ 0x0000000000a1cf6c
12 clang++ 0x0000000000a1e449
13 clang++ 0x0000000000a13943
14 clang++ 0x0000000000a342dc
15 clang++ 0x0000000000a34b08
16 clang++ 0x0000000000a34be6
17 clang++ 0x0000000000a17830
18 clang++ 0x0000000000a0a0ae
19 clang++ 0x0000000000a0a2e0
20 clang++ 0x0000000000686b83
21 clang++ 0x000000000045e26c
22 clang++ 0x000000000045e369
23 clang++ 0x000000000044afa5
24 clang++ 0x0000000000431e94
25 clang++ 0x0000000000436338 main + 233
26 libc.so.6 0x00000036a9c1e576 __libc_start_main + 230
27 clang++ 0x0000000000430d19
Stack dump:
0. Program arguments: /home/abagnara/llvm_new/Debug/bin/clang++ -cc1 bug.cc
1. bug.cc:6:24: current parser token 'a'
2. bug.cc:5:1: parsing struct/union/class body 's'
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list