Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/c-c++-common/raw-string-17.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 /* PR preprocessor/57824 */ | |
2 /* { dg-do run } */ | |
3 /* { dg-options "-std=gnu99" { target c } } */ | |
4 /* { dg-options "-std=c++11" { target c++ } } */ | |
5 | |
6 #define S(s) s | |
7 #define T(s) s "\n" | |
8 | |
9 const char x[] = R"( | |
10 abc | |
11 )"; | |
12 const char y[] = S(R"( | |
13 abc | |
14 )"); | |
15 const char z[] = "\nabc\n"; | |
16 const char w[] = T(R"( | |
17 abc)"); | |
18 | |
19 int | |
20 main () | |
21 { | |
22 if (sizeof x != sizeof y | |
23 || sizeof x != sizeof z | |
24 || sizeof x != sizeof w | |
25 || __builtin_memcmp (x, y, sizeof x) | |
26 || __builtin_memcmp (x, z, sizeof x) | |
27 || __builtin_memcmp (x, w, sizeof x)) | |
28 __builtin_abort (); | |
29 return 0; | |
30 } |