[Bug c++/56614] [4.7/4.8 Regression] error: default argument 'std::vector<E>(std::initializer_list<E>{((const E*)(& ._0)), 1u}, (*(const std::allocator<E>*)(& std::allocator<E>())))' uses local variable '._0'
paolo.carlini at oracle dot com
gcc-bugzilla@gcc.gnu.org
Wed Mar 13 17:29:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56614
--- Comment #2 from Paolo Carlini <paolo.carlini at oracle dot com> 2013-03-13 17:29:02 UTC ---
A few details can be removed from the testcase:
#include <initializer_list>
struct vector
{
vector(std::initializer_list<int>);
};
void func();
struct C
{
template<typename T>
C(T, vector = vector({}));
};
C c(func);
More information about the Gcc-bugs
mailing list