[LLVMbugs] [Bug 22255] New: Crash on implicit member access in initializer in dependent type
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat Jan 17 17:09:21 PST 2015
http://llvm.org/bugs/show_bug.cgi?id=22255
Bug ID: 22255
Summary: Crash on implicit member access in initializer in
dependent type
Product: clang
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P
Component: C++11
Assignee: unassignedclangbugs at nondot.org
Reporter: nicolasweber at gmx.de
CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
Classification: Unclassified
This crashes:
template <class> void redundant_typename() {
struct A {
int pT = pT;
};
};
void f() {
redundant_typename<int>();
}
If the initializer is spelled `= this->pT;` instead, it works. That's because
the initializer is a CXXDependentScopeMemberExpr in that case, because
Sema::ActOnMemberAccessExpr() calls ActOnDependentMemberExpr() for dependent
members. Sema::BuildImplicitMemberExpr() doesn't do that -- adding code to do
that makes the crash go away, but I'm pretty unsure if that's the right fix.
--
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/20150118/fa93f3af/attachment.html>
More information about the llvm-bugs
mailing list