ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsctordeferred_resndemanglerenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxmemorynew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newwith_gc
Last change
on this file since 5479e63 was
e757af2,
checked in by Thierry Delisle <tdelisle@…>, 8 years ago
|
renamed all tests to lower-case leading character
|
-
Property mode set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | int main() { |
---|
2 | // character constants |
---|
3 | |
---|
4 | ' '; |
---|
5 | 'a'; |
---|
6 | '"'; |
---|
7 | '_'; |
---|
8 | |
---|
9 | '\a'; // simple escape |
---|
10 | '\b'; |
---|
11 | '\e'; // GCC |
---|
12 | '\f'; |
---|
13 | '\n'; |
---|
14 | '\r'; |
---|
15 | '\t'; |
---|
16 | '\v'; |
---|
17 | '\''; |
---|
18 | '\"'; |
---|
19 | '\?'; |
---|
20 | '\\'; |
---|
21 | |
---|
22 | '\0'; // octal escape |
---|
23 | |
---|
24 | '\377'; |
---|
25 | |
---|
26 | '\xf'; // hex escape |
---|
27 | '\xff'; |
---|
28 | |
---|
29 | // warnings/errors |
---|
30 | |
---|
31 | ''; // empty character |
---|
32 | 'aa'; // multi-character |
---|
33 | 'a\na'; // multi-character, embedded escape |
---|
34 | 'a\0a'; |
---|
35 | '\xfff'; // hex escape out of range |
---|
36 | '_\377_'; // multi-character |
---|
37 | '_\xff_'; |
---|
38 | '\xffff'; // hex escape out of range |
---|
39 | 'a\xff34w'; |
---|
40 | '\xf_f'; // multi-character |
---|
41 | '\xff_ff'; |
---|
42 | |
---|
43 | // string constants |
---|
44 | |
---|
45 | " "; |
---|
46 | "a"; |
---|
47 | "'"; |
---|
48 | '_'; |
---|
49 | |
---|
50 | "\a"; // simple escape |
---|
51 | "\b"; |
---|
52 | "\e"; // GCC |
---|
53 | "\f"; |
---|
54 | "\n"; |
---|
55 | "\r"; |
---|
56 | "\t"; |
---|
57 | "\v"; |
---|
58 | "\'"; |
---|
59 | "\""; |
---|
60 | "\?"; |
---|
61 | "\\"; |
---|
62 | |
---|
63 | "\0"; // octal escape |
---|
64 | "\377"; |
---|
65 | |
---|
66 | "\xf"; // hex escape |
---|
67 | "\xff"; |
---|
68 | |
---|
69 | ""; |
---|
70 | "aa"; |
---|
71 | "a\na"; |
---|
72 | "a\0a"; |
---|
73 | "_\377_"; |
---|
74 | "_\xff_"; |
---|
75 | "\xf_f"; |
---|
76 | |
---|
77 | // warnings/errors |
---|
78 | |
---|
79 | "\xff_ff"; |
---|
80 | "\xfff"; // hex escape out of range |
---|
81 | "a\xff34w"; |
---|
82 | "\xffff"; |
---|
83 | } |
---|
84 | |
---|
85 | // Local Variables: // |
---|
86 | // compile-command: "../../../bin/cfa -std=c99 CharStringConstants.c" // |
---|
87 | // End: // |
---|
Note: See
TracBrowser
for help on using the repository browser.