[LLVMbugs] [Bug 7896] New: c++ crash with overloading and using decl in class template
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat Aug 14 16:38:01 PDT 2010
http://llvm.org/bugs/show_bug.cgi?id=7896
Summary: c++ crash with overloading and using decl in class
template
Product: clang
Version: unspecified
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: sharparrow1 at yahoo.com
CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com
Testcase:
template <class T> struct Foo {
int k (float);
};
struct Baz {
int k (int);
};
template <class T> struct Bar : public Foo<T>, Baz {
using Foo<T>::k;
using Baz::k;
int foo() {
return k (1.0f);
}
};
template int Bar<int>::foo();
Crashes with:
clang: SemaTemplateInstantiateDecl.cpp:2688: clang::NamedDecl*
clang::Sema::FindInstantiatedDecl(clang::SourceLocation, clang::NamedDecl*,
const clang::MultiLevelTemplateArgumentList&): Assertion `(Result ||
isa<UsingShadowDecl>(D) || D->isInvalidDecl() ||
cast<Decl>(ParentDC)->isInvalidDecl()) && "Unable to find instantiation of
declaration!"' failed.
--
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