<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Crash while refactor function with range based for"
href="https://llvm.org/bugs/show_bug.cgi?id=25227">25227</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Crash while refactor function with range based for
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Frontend
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>jvapen@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=15089" name="attach_15089" title="Reproduction scenario">attachment 15089</a> <a href="attachment.cgi?id=15089&action=edit" title="Reproduction scenario">[details]</a></span>
Reproduction scenario
error: use of undeclared identifier 'tests'; did you mean 'test'? [Semantic
Issue]
for (std::unique_ptr<ITestCase> &test : tests)
^~~~~
test
Trunk revision: 250612
Failed assertion:
void
clang::ClassTemplateSpecializationDecl::setPointOfInstantiation(clang::SourceLocation):
Assertion `Loc.isValid() && "point of instantiation must be valid!"' failed.
Related trace:
clang::Sema::InstantiateClass(clang::SourceLocation, clang::CXXRecordDecl*,
clang::CXXRecordDecl*, clang::MultiLevelTemplateArgumentList const&,
clang::TemplateSpecializationKind, bool) + 358
clang::Sema::InstantiateClassTemplateSpecialization(clang::SourceLocation,
clang::ClassTemplateSpecializationDecl*, clang::TemplateSpecializationKind,
bool) + 2287
clang::Sema::RequireCompleteTypeImpl(clang::SourceLocation, clang::QualType,
clang::Sema::TypeDiagnoser&) + 1112
clang::Sema::RequireCompleteType(clang::SourceLocation, clang::QualType,
clang::Sema::TypeDiagnoser&) + 86
clang::Sema::RequireCompleteType(clang::SourceLocation, clang::QualType,
unsigned int) + 82
clang::Sema::BuildCXXForRangeStmt(clang::SourceLocation, clang::SourceLocation,
clang::Stmt*, clang::Stmt*, clang::Expr*, clang::Expr*, clang::Stmt*,
clang::SourceLocation, clang::Sema::BuildForRangeKind) + 1082
clang::Sema::ActOnCXXForRangeStmt(clang::SourceLocation, clang::Stmt*,
clang::SourceLocation, clang::Expr*, clang::SourceLocation,
clang::Sema::BuildForRangeKind) + 970
clang::Parser::ParseForStatement(clang::SourceLocation*) + 4863
clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector<clang::Stmt*,
32u>&, bool, clang::SourceLocation*, clang::Parser::ParsedAttributesWithRange&)
+ 2888
clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector<clang::Stmt*,
32u>&, bool, clang::SourceLocation*) + 125
clang::Parser::ParseCompoundStatementBody(bool) + 1282
clang::Parser::ParseFunctionStatementBody(clang::Decl*,
clang::Parser::ParseScope&) + 316
clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&,
clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) +
3639
clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, unsigned int,
clang::SourceLocation*, clang::Parser::ForRangeInit*) + 995
clang::Parser::ParseDeclOrFunctionDefInternal(clang::Parser::ParsedAttributesWithRange&,
clang::ParsingDeclSpec&, clang::AccessSpecifier) + 1163
clang::Parser::ParseDeclarationOrFunctionDefinition(clang::Parser::ParsedAttributesWithRange&,
clang::ParsingDeclSpec*, clang::AccessSpecifier) + 147
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::ParsingDeclSpec*) + 3659
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 1030
clang::ParseAST(clang::Sema&, bool, bool) + 949
clang::ASTFrontendAction::ExecuteAction() + 511
clang::CodeGenAction::ExecuteAction() + 5776
clang::FrontendAction::Execute() + 112
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 1416
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 4193
cc1_main(llvm::ArrayRef<char const*>, char const*, void*) + 4544</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>