1 // { dg-do compile { target c++11 } }
4 const char s0[] = u8"ab";
5 const char16_t s1[] = u8"ab"; // { dg-error "from non-wide" }
6 const char32_t s2[] = u8"ab"; // { dg-error "from non-wide" }
7 const wchar_t s3[] = u8"ab"; // { dg-error "from non-wide" }
9 const char t0[0] = u8"ab"; // { dg-error "chars is too long" }
10 const char t1[1] = u8"ab"; // { dg-error "chars is too long" }
11 const char t2[2] = u8"ab"; // { dg-error "chars is too long" }
12 const char t3[3] = u8"ab";
13 const char t4[4] = u8"ab";
15 const char u0[0] = u8"\u2160."; // { dg-error "chars is too long" }
16 const char u1[1] = u8"\u2160."; // { dg-error "chars is too long" }
17 const char u2[2] = u8"\u2160."; // { dg-error "chars is too long" }
18 const char u3[3] = u8"\u2160."; // { dg-error "chars is too long" }
19 const char u4[4] = u8"\u2160."; // { dg-error "chars is too long" }
20 const char u5[5] = u8"\u2160.";
21 const char u6[6] = u8"\u2160.";