[LLVMbugs] [Bug 12890] New: ICE involving delegating constructors and variadic constructors
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat May 19 14:06:56 PDT 2012
http://llvm.org/bugs/show_bug.cgi?id=12890
Bug #: 12890
Summary: ICE involving delegating constructors and variadic
constructors
Product: clang
Version: trunk
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P
Component: C++11
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: hhinnant at apple.com
CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
Classification: Unclassified
With tip-of-trunk I'm getting an internal compiler error with (-std=c++11):
class Document
{
public:
Document() = default;
template <class T, class ...Args>
explicit
Document(T&& t, Args&& ...args)
: Document()
{
}
};
int main()
{
Document d(1);
}
The expectation is for it to compile.
0 clang 0x000000011234822e _ZL15PrintStackTracePv + 46
1 clang 0x0000000112348848 _ZL13SignalHandleri + 408
2 libsystem_c.dylib 0x00007fff8e126cfa _sigtramp + 26
3 libsystem_c.dylib 0x00007fd6f282ef70 _sigtramp + 18446743899300987536
4 clang 0x0000000110ed84c5
clang::ParenListExpr::classof(clang::Stmt const*) + 21
5 clang 0x0000000110ed84a5 llvm::isa_impl<clang::ParenListExpr,
clang::Expr>::doit(clang::Expr const&) + 21
6 clang 0x000000011032ff45 llvm::isa_impl_cl<clang::ParenListExpr,
clang::Expr*>::doit(clang::Expr const*) + 21
7 clang 0x000000011032ff18
llvm::isa_impl_wrap<clang::ParenListExpr, clang::Expr*,
clang::Expr*>::doit(clang::Expr* const&) + 24
8 clang 0x00000001103165f5 bool llvm::isa<clang::ParenListExpr,
clang::Expr*>(clang::Expr* const&) + 21
9 clang 0x0000000110316515 llvm::cast_retty<clang::ParenListExpr,
clang::Expr*>::ret_type llvm::dyn_cast<clang::ParenListExpr,
clang::Expr*>(clang::Expr* const&) + 21
10 clang 0x000000011020081d
clang::Sema::BuildDelegatingInitializer(clang::TypeSourceInfo*, clang::Expr*,
clang::CXXRecordDecl*) + 365
11 clang 0x0000000110537e74
clang::Sema::InstantiateMemInitializers(clang::CXXConstructorDecl*,
clang::CXXConstructorDecl const*, clang::MultiLevelTemplateArgumentList const&)
+ 1908
12 clang 0x0000000110537389
clang::Sema::InstantiateFunctionDefinition(clang::SourceLocation,
clang::FunctionDecl*, bool, bool) + 3017
13 clang 0x0000000110538703
clang::Sema::PerformPendingInstantiations(bool) + 1219
14 clang 0x000000011010bbd7
clang::Sema::ActOnEndOfTranslationUnit() + 615
15 clang 0x00000001100a8b92
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 338
16 clang 0x00000001100392c1 clang::ParseAST(clang::Sema&, bool,
bool) + 449
17 clang 0x000000010fcb4ea9
clang::ASTFrontendAction::ExecuteAction() + 489
18 clang 0x000000010ffcf071 clang::CodeGenAction::ExecuteAction() +
1505
19 clang 0x000000010fcb4a17 clang::FrontendAction::Execute() + 231
20 clang 0x000000010fc78e64
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 916
21 clang 0x000000010fc46a3f
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1855
22 clang 0x000000010fc29702 cc1_main(char const**, char const**,
char const*, void*) + 1186
23 clang 0x000000010fc3caa6 main + 566
24 clang 0x000000010fc29234 start + 52
Stack dump:
0. Program arguments:
/Users/hhinnant/Development/llvm/build/Debug+Asserts/bin/clang -cc1 -triple
x86_64-apple-macosx10.7.0 -emit-obj -mrelax-all -disable-free -main-file-name
test.cpp -pic-level 2 -mdisable-fp-elim -masm-verbose -munwind-tables
-target-cpu core2 -target-linker-version 134.1 -resource-dir
/Users/hhinnant/Development/llvm/build/Debug+Asserts/bin/../lib/clang/3.2
-fmodule-cache-path
/var/folders/5q/jl417kxs70j1jn8pz_mclngm0000gn/T/clang-module-cache -std=c++11
-fdeprecated-macro -fdebug-compilation-dir /Users/hhinnant/Development/cljunk
-ferror-limit 19 -fmessage-length 162 -stack-protector 1 -mstackrealign
-fblocks -fobjc-runtime-has-arc -fobjc-runtime-has-weak
-fobjc-dispatch-method=mixed -fobjc-default-synthesize-properties
-fcxx-exceptions -fexceptions -fdiagnostics-show-option -fcolor-diagnostics -o
/var/folders/5q/jl417kxs70j1jn8pz_mclngm0000gn/T/test-cSM2xb.o -x c++ test.cpp
1. <eof> parser at end of file
2. test.cpp:8:5: instantiating function definition 'Document'
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
clang: note: diagnostic msg: Please submit a bug report to
http://llvm.org/bugs/ and include command line arguments and all diagnostic
information.
clang: note: diagnostic msg: Preprocessed source(s) and associated run
script(s) are located at:
clang: note: diagnostic msg:
/var/folders/5q/jl417kxs70j1jn8pz_mclngm0000gn/T/test-p6zFd7.ii
clang: note: diagnostic msg:
/var/folders/5q/jl417kxs70j1jn8pz_mclngm0000gn/T/test-p6zFd7.sh
--
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