http://llvm.org/bugs/show_bug.cgi?id=6928
Summary: Assertion with implicitly-generated copy constructor
call with default arguments
Product: clang
Version: trunk
Platform: PC
OS/Version: All
Status: NEW
Severity: normal
Priority: P
Component: C++
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected], [email protected]
cove:clang dgregor$ cat t2.C
template <typename T>
struct X {
X();
X(const X&, bool = false);
};
struct Y {
X<int> x;
};
void f(Y);
void g() {
Y y;
f(y);
}
cove:clang dgregor$ clang++ t2.C
Assertion failed: (!hasUninstantiatedDefaultArg() && "Default argument is not
yet instantiated!"), function getDefaultArg, file
/Users/dgregor/Projects/llvm/tools/clang/lib/AST/Decl.cpp, line 845.
The problem here is that CodeGen is poking directly at the default arguments of
the ParmVarDecls in the copy constructor when it generates the copy-constructor
call, rather than letting Sema do that work.
--
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.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs