re PR c++/50478 ([C++0x] Internal compiler error when using initializer lists)
2012-10-10 Paolo Carlini <paolo.carlini@oracle.com> PR c++/50478 * g++.dg/cpp0x/initlist67.C: New. From-SVN: r192295
This commit is contained in:
parent
c8855f2d8e
commit
d8cfe70799
2 changed files with 32 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2012-10-10 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/50478
|
||||
* g++.dg/cpp0x/initlist67.C: New.
|
||||
|
||||
2012-10-10 Dehao Chen <dehao@google.com>
|
||||
|
||||
* g++.dg/debug/dwarf2/deallocator.C: Cover more deallocator cases.
|
||||
|
|
27
gcc/testsuite/g++.dg/cpp0x/initlist67.C
Normal file
27
gcc/testsuite/g++.dg/cpp0x/initlist67.C
Normal file
|
@ -0,0 +1,27 @@
|
|||
// PR c++/50478
|
||||
// { dg-do compile { target c++11 } }
|
||||
|
||||
#include <initializer_list>
|
||||
|
||||
namespace std
|
||||
{
|
||||
template<typename _Key>
|
||||
struct set
|
||||
{
|
||||
void insert(const _Key&);
|
||||
void insert(initializer_list<_Key>);
|
||||
};
|
||||
|
||||
struct string
|
||||
{
|
||||
string(const string&, __SIZE_TYPE__, __SIZE_TYPE__ = -1);
|
||||
string(const char*);
|
||||
string(initializer_list<char>);
|
||||
};
|
||||
}
|
||||
|
||||
int main()
|
||||
{
|
||||
std::set<std::string> s;
|
||||
s.insert( { "abc", "def", "hij"} );
|
||||
}
|
Loading…
Add table
Reference in a new issue