<html>
    <head>
      <base href="http://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 in template matching"
   href="http://llvm.org/bugs/show_bug.cgi?id=15436">15436</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Crash in template matching
          </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>yu.valery+bugzilla@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=10136" name="attach_10136" title="Preprocessed source and run script">attachment 10136</a> <a href="attachment.cgi?id=10136&action=edit" title="Preprocessed source and run script">[details]</a></span>
Preprocessed source and run script

clang:
/lscrs/yundin/stuff/src/llvm/tools/clang/lib/Sema/../../include/clang/AST/DeclTemplate.h:1509:
void
clang::ClassTemplateSpecializationDecl::setInstantiationOf(clang::ClassTemplatePartialSpecializationDecl*,
clang::TemplateArgumentList*): Assertion
`!SpecializedTemplate.is<SpecializedPartialSpecialization*>() && "Already set
to a class template partial specialization!"' failed.
0  clang           0x0000000001d70b22 llvm::sys::PrintStackTrace(_IO_FILE*) +
34
1  clang           0x0000000001d70f49
2  libpthread.so.0 0x0000003dfe80f500
3  libc.so.6       0x0000003dfdc328a5 gsignal + 53
4  libc.so.6       0x0000003dfdc34085 abort + 373
5  libc.so.6       0x0000003dfdc2ba1e
6  libc.so.6       0x0000003dfdc2bae0 __assert_perror_fail + 0
7  clang           0x0000000000cc06a1
8  clang           0x0000000000cfa633
clang::Sema::RequireCompleteType(clang::SourceLocation, clang::QualType,
clang::Sema::TypeDiagnoser&) + 1283
9  clang           0x0000000000a20e94
clang::Sema::RequireCompleteDeclContext(clang::CXXScopeSpec&,
clang::DeclContext*) + 308
10 clang           0x0000000000c39fd6
clang::Sema::CheckTypenameType(clang::ElaboratedTypeKeyword,
clang::SourceLocation, clang::NestedNameSpecifierLoc, clang::IdentifierInfo
const&, clang::SourceLocation) + 198
11 clang           0x0000000000cb36f9
12 clang           0x0000000000ca9f13
13 clang           0x0000000000cac850
14 clang           0x0000000000cad603
clang::Sema::SubstType(clang::TypeSourceInfo*,
clang::MultiLevelTemplateArgumentList const&, clang::SourceLocation,
clang::DeclarationName) + 163
15 clang           0x0000000000ca8367
clang::Sema::SubstParmVarDecl(clang::ParmVarDecl*,
clang::MultiLevelTemplateArgumentList const&, int, llvm::Optional<unsigned
int>, bool) + 135
16 clang           0x0000000000ca8c22
17 clang           0x0000000000ca97b0
18 clang           0x0000000000cac2d8
clang::Sema::SubstFunctionDeclType(clang::TypeSourceInfo*,
clang::MultiLevelTemplateArgumentList const&, clang::SourceLocation,
clang::DeclarationName, clang::CXXRecordDecl*, unsigned int) + 1400
19 clang           0x0000000000cd3168
clang::TemplateDeclInstantiator::SubstFunctionType(clang::FunctionDecl*,
llvm::SmallVectorImpl<clang::ParmVarDecl*>&) + 232
20 clang           0x0000000000cd64fd
clang::TemplateDeclInstantiator::VisitFunctionDecl(clang::FunctionDecl*,
clang::TemplateParameterList*) + 301
21 clang           0x0000000000cd95c4 clang::Sema::SubstDecl(clang::Decl*,
clang::DeclContext*, clang::MultiLevelTemplateArgumentList const&) + 100
22 clang           0x0000000000c82d16
clang::Sema::FinishTemplateArgumentDeduction(clang::FunctionTemplateDecl*,
llvm::SmallVectorImpl<clang::DeducedTemplateArgument>&, unsigned int,
clang::FunctionDecl*&, clang::sema::TemplateDeductionInfo&,
llvm::SmallVectorImpl<clang::Sema::OriginalCallArg> const*) + 2358
23 clang           0x0000000000c850e9
clang::Sema::DeduceTemplateArguments(clang::FunctionTemplateDecl*,
clang::TemplateArgumentListInfo*, llvm::ArrayRef<clang::Expr*>,
clang::FunctionDecl*&, clang::sema::TemplateDeductionInfo&) + 729
24 clang           0x0000000000bfe624
clang::Sema::AddTemplateOverloadCandidate(clang::FunctionTemplateDecl*,
clang::DeclAccessPair, clang::TemplateArgumentListInfo*,
llvm::ArrayRef<clang::Expr*>, clang::OverloadCandidateSet&, bool) + 340
25 clang           0x0000000000c0034d
clang::Sema::AddOverloadedCallCandidates(clang::UnresolvedLookupExpr*,
llvm::ArrayRef<clang::Expr*>, clang::OverloadCandidateSet&, bool) + 429
26 clang           0x0000000000c005b1
clang::Sema::buildOverloadedCallSet(clang::Scope*, clang::Expr*,
clang::UnresolvedLookupExpr*, clang::Expr**, unsigned int,
clang::SourceLocation, clang::OverloadCandidateSet*,
clang::ActionResult<clang::Expr*, true>*) + 289
27 clang           0x0000000000c00f4b
clang::Sema::BuildOverloadedCallExpr(clang::Scope*, clang::Expr*,
clang::UnresolvedLookupExpr*, clang::SourceLocation, clang::Expr**, unsigned
int, clang::SourceLocation, clang::Expr*, bool) + 427
28 clang           0x0000000000b5dccf clang::Sema::ActOnCallExpr(clang::Scope*,
clang::Expr*, clang::SourceLocation, llvm::MutableArrayRef<clang::Expr*>,
clang::SourceLocation, clang::Expr*, bool) + 1343
29 clang           0x00000000009b78b7
clang::Parser::ParsePostfixExpressionSuffix(clang::ActionResult<clang::Expr*,
true>) + 2807
30 clang           0x00000000009b0aab clang::Parser::ParseCastExpression(bool,
bool, bool&, clang::Parser::TypeCastState) + 203
31 clang           0x00000000009b313d clang::Parser::ParseCastExpression(bool,
bool, clang::Parser::TypeCastState) + 29
32 clang           0x00000000009b463f
clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) + 31
33 clang           0x000000000098f5a0
clang::Parser::ParseDeclarationAfterDeclaratorAndAttributes(clang::Declarator&,
clang::Parser::ParsedTemplateInfo const&) + 544
34 clang           0x0000000000994a83
clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, unsigned int, bool,
clang::SourceLocation*, clang::Parser::ForRangeInit*) + 1059
35 clang           0x000000000099b11e
clang::Parser::ParseSimpleDeclaration(llvm::SmallVector<clang::Stmt*, 32u>&,
unsigned int, clang::SourceLocation&,
clang::Parser::ParsedAttributesWithRange&, bool, clang::Parser::ForRangeInit*)
+ 750
36 clang           0x000000000099b36b
clang::Parser::ParseDeclaration(llvm::SmallVector<clang::Stmt*, 32u>&, unsigned
int, clang::SourceLocation&, clang::Parser::ParsedAttributesWithRange&) + 219
37 clang           0x00000000009e3159
clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector<clang::Stmt*,
32u>&, bool, clang::SourceLocation*, clang::Parser::ParsedAttributesWithRange&)
+ 377
38 clang           0x00000000009e3bfe
clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector<clang::Stmt*,
32u>&, bool, clang::SourceLocation*) + 142
39 clang           0x00000000009e102c
clang::Parser::ParseCompoundStatementBody(bool) + 1916
40 clang           0x00000000009e861d
clang::Parser::ParseFunctionStatementBody(clang::Decl*,
clang::Parser::ParseScope&) + 141
41 clang           0x0000000000989733
clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&,
clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) +
1795
42 clang           0x0000000000994da1
clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, unsigned int, bool,
clang::SourceLocation*, clang::Parser::ForRangeInit*) + 1857
43 clang           0x00000000009862c5
clang::Parser::ParseDeclOrFunctionDefInternal(clang::Parser::ParsedAttributesWithRange&,
clang::ParsingDeclSpec&, clang::AccessSpecifier) + 245
44 clang           0x00000000009869e0
clang::Parser::ParseDeclarationOrFunctionDefinition(clang::Parser::ParsedAttributesWithRange&,
clang::ParsingDeclSpec*, clang::AccessSpecifier) + 976
45 clang           0x0000000000987d8d
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::ParsingDeclSpec*) + 77
46 clang           0x00000000009884c8
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 184
47 clang           0x000000000098050d clang::ParseAST(clang::Sema&, bool, bool)
+ 493
48 clang           0x00000000006beac9 clang::FrontendAction::Execute() + 153
49 clang           0x00000000006a32cd
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 349
50 clang           0x000000000068b536
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1478
51 clang           0x0000000000682d88 cc1_main(char const**, char const**, char
const*, void*) + 920
52 clang           0x0000000000689dad main + 637
53 libc.so.6       0x0000003dfdc1ecdd __libc_start_main + 253
54 clang           0x0000000000682879
Stack dump:
0.    Program arguments: /lscrs/yundin/bin/clang -cc1 -triple
x86_64-unknown-linux-gnu -emit-obj -mrelax-all -disable-free -main-file-name
spntest.cpp -mrelocation-model static -mdisable-fp-elim -fmath-errno
-masm-verbose -mconstructor-aliases -munwind-tables -fuse-init-array
-target-cpu x86-64 -target-linker-version 2.20.51.0.2 -momit-leaf-frame-pointer
-resource-dir /lscrs/yundin/bin/../lib/clang/3.3 -fmodule-cache-path
/var/tmp/clang-module-cache -c-isystem /lscrs/yundin/include -cxx-isystem
/lscrs/yundin/include -internal-isystem
/lscrs/yundin/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.2/../../../../include/c++/4.7.2
-internal-isystem
/lscrs/yundin/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.2/../../../../include/c++/4.7.2/x86_64-unknown-linux-gnu
-internal-isystem
/lscrs/yundin/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.2/../../../../include/c++/4.7.2/backward
-internal-isystem /usr/local/include -internal-isystem
/lscrs/yundin/bin/../lib/clang/3.3/include -internal-externc-isystem /include
-internal-
externc-isystem /usr/include -fdeprecated-macro -fdebug-compilation-dir
/lscrm/yundin/cache/clang1/example -ferror-limit 19 -fmessage-length 0
-mstackrealign -fobjc-runtime=gcc -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -backend-option -vectorize-loops -o
/tmp/spntest-wTc9aJ.o -x c++ spntest.cpp 
1.    spntest.cpp:12:42: current parser token ')'
2.    spntest.cpp:6:1: parsing function body 'main'
3.    spntest.cpp:6:1: in compound statement ('{}')
clang: error: unable to execute command: Aborted (core dumped)
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
clang version 3.3 (trunk 173275)
Target: x86_64-unknown-linux-gnu
Thread model: posix
clang: note: diagnostic msg: PLEASE submit a bug report to
<a href="http://llvm.org/bugs/">http://llvm.org/bugs/</a> and include the crash backtrace, preprocessed source, and
associated run script.
clang: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /tmp/spntest-e36xRe.cpp
clang: note: diagnostic msg: /tmp/spntest-e36xRe.sh
clang: note: diagnostic msg: 

********************</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>