forked from OSchip/llvm-project
19 lines
353 B
C++
19 lines
353 B
C++
|
// RUN: %clang_cc1 -fsyntax-only -std=c++0x %s -verify
|
||
|
|
||
|
namespace PR10457 {
|
||
|
|
||
|
class string
|
||
|
{
|
||
|
string(const char* str, unsigned);
|
||
|
|
||
|
public:
|
||
|
template <unsigned N>
|
||
|
string(const char (&str)[N])
|
||
|
: string(str) {} // expected-error{{constructor for 'string<6>' creates a delegation cycle}}
|
||
|
};
|
||
|
|
||
|
void f() {
|
||
|
string s("hello");
|
||
|
}
|
||
|
}
|