llvm-project
llvm-project copied to clipboard
assert in clang::TemplateDeclInstantiator::VisitOMPDeclareReductionDecl
| Bugzilla Link | 38903 |
| Resolution | FIXED |
| Resolved on | Sep 13, 2018 09:55 |
| Version | unspecified |
| OS | All |
| CC | @alexey-bataev |
Extended Description
struct U
{
void foo(U&, bool);
U();
};
template
$ clang++ -fopenmp d3.cpp
clang-8: /llvm/tools/clang/lib/Sema/SemaTemplateInstantiate.cpp:2933: llvm::PointerUnion<clang::Decl*, llvm::SmallVector<clang::ParmVarDecl*, 4u>> clang::LocalInstantiationScope::findInstantiationOf(const clang::Decl*): Assertion `isa
- d3.cpp:13:53: current parser token 'foo'
- d3.cpp:7:8: instantiating class definition 'S<1>' #0 0x000000001387ee00 llvm::sys::PrintStackTrace(llvm::raw_ostream&) /llvm/lib/Support/Unix/Signals.inc:490:0 #1 0x000000001387ef04 PrintStackTraceSignalHandler(void*) /llvm/lib/Support/Unix/Signals.inc:553:0 #2 0x000000001387c568 llvm::sys::RunSignalHandlers() /llvm/lib/Support/Signals.cpp:66:0 #3 0x000000001387e4f4 SignalHandler(int) /llvm/lib/Support/Unix/Signals.inc:343:0 #4 0x00003fffad940478 0x478 __GI_abort #5 0x00003fffad940478 #6 0x00003fffad940478 __assert_fail_base (+0x478) #7 0x00003fffad3b0d70 __GI___assert_fail (/lib64/libc.so.6+0x40d70) #8 0x00003fffad3a48a4 clang::LocalInstantiationScope::findInstantiationOf(clang::Decl const*) /llvm/tools/clang/lib/Sema/SemaTemplateInstantiate.cpp:2933:0 #9 0x00003fffad3a4994 clang::TemplateDeclInstantiator::VisitOMPDeclareReductionDecl(clang::OMPDeclareReductionDecl*) /llvm/tools/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp:2750:0 #10 0x0000000017c11620 clang::declvisitor::Base<clang::declvisitor::make_ptr, clang::TemplateDeclInstantiator, clang::Decl*>::Visit(clang::Decl*) /clang/build/tools/clang/include/clang/AST/DeclNodes.inc:503:0 ...
Fixed in r342151