1 # Syntax rules for the C and the C++ programming languages
3 # List of keywords is based on opencl-mode.el from
4 # Salmane Bah <salmane.bah@u-bordeaux.fr>
7 keyword whole auto yellow
8 keyword whole break yellow
9 keyword whole case yellow
10 keyword whole char yellow
11 keyword whole const yellow
12 keyword whole continue yellow
13 keyword whole do yellow
14 keyword whole double yellow
15 keyword whole else yellow
16 keyword whole enum yellow
17 keyword whole extern yellow
18 keyword whole float yellow
19 keyword whole for yellow
20 keyword whole goto yellow
21 keyword whole if yellow
22 keyword whole int yellow
23 keyword whole long yellow
24 keyword whole register yellow
25 keyword whole return yellow
26 keyword whole short yellow
27 keyword whole signed yellow
28 keyword whole sizeof yellow
29 keyword whole static yellow
30 keyword whole struct yellow
31 keyword whole switch yellow
32 keyword whole typedef yellow
33 keyword whole union yellow
34 keyword whole unsigned yellow
35 keyword whole void yellow
36 keyword whole volatile yellow
37 keyword whole while yellow
38 keyword whole asm yellow
39 keyword whole inline yellow
40 keyword whole wchar_t yellow
41 keyword whole ... yellow
42 keyword whole linestart \{\s\t\}\[\s\t\]#*\n brightmagenta
43 keyword whole \[\s\t\]default yellow
44 keyword whole linestart \[\s\t\]\{ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz\}\[0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz\]: cyan
46 # Function type qualifiers
47 keyword whole __kernel white
49 # Variable type qualifiers
50 keyword whole __global white
51 keyword whole __local white
52 keyword whole __constant white
53 keyword whole __private white
54 keyword whole __read_only white
55 keyword whole __write_only white
56 keyword whole __read_write white
57 keyword whole __enable white
58 keyword whole __disable white
59 keyword whole global white
60 keyword whole local white
61 keyword whole constant white
62 keyword whole private white
63 keyword whole read_only white
64 keyword whole write_only white
65 keyword whole read_write white
66 keyword whole enable white
67 keyword whole disable white
70 keyword whole get_group_id brightmagenta
71 keyword whole get_local_id brightmagenta
72 keyword whole get_global_id brightmagenta
73 keyword whole get_local_size brightmagenta
74 keyword whole get_global_size brightmagenta
75 keyword whole get_work_dim brightmagenta
76 keyword whole get_num_groups brightmagenta
77 keyword whole get_global_offset brightmagenta
78 keyword whole barrier brightmagenta
81 keyword whole CLK_LOCAL_MEM_FENCE white
82 keyword whole CLK_GLOBAL_MEM_FENCE white
83 keyword whole MAXFLOAT white
84 keyword whole HUGE_VAL white
85 keyword whole HUGE_VALF white
86 keyword whole INFINITY white
87 keyword whole NAN white
90 keyword whole half yellow
91 keyword whole uchar yellow
92 keyword whole ushort yellow
93 keyword whole uint yellow
94 keyword whole ulong yellow
95 keyword whole bool yellow
96 keyword whole size_t yellow
97 keyword whole ptrdiff_t yellow
98 keyword whole intptr_t yellow
99 keyword whole uintptr_t yellow
101 keyword whole image2d_t yellow
102 keyword whole image3d_t yellow
103 keyword whole image2d_array_t yellow
104 keyword whole image3d_array_t yellow
105 keyword whole image1d_array_t yellow
106 keyword whole image1d_t yellow
107 keyword whole image1d_buffer_t yellow
108 keyword whole sampler_t yellow
109 keyword whole event_t yellow
111 keyword whole cl_khr_\{ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz\}\{ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_\}+ brightgreen
117 keyword '\\\{"abtnvfr\}' brightgreen
118 keyword '\\\{0123\}\{01234567\}\{01234567\}' brightgreen
119 keyword '\\'' brightgreen
120 keyword '\\\\' brightgreen
121 keyword '\\0' brightgreen
122 keyword '\{\s!"#$%&()\*\+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[]^_`abcdefghijklmnopqrstuvwxyz{|}~ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ\}' brightgreen
124 # punctuation characters, sorted by ASCII code
128 keyword & brightmagenta
137 keyword ; brightmagenta
144 keyword ^ brightmagenta
147 keyword | brightmagenta
149 keyword ~ brightmagenta
151 context exclusive /\* \*/ brown
154 context exclusive // \n brown
157 context linestart # \n brightred
159 keyword /\**\*/ brown
166 keyword \\" brightgreen
167 keyword %% brightgreen
168 keyword %\[#0\s-\+,\]\[0123456789\*\]\[.\]\[0123456789\*\]\[L\]\{eEfgGoxX\} brightgreen
169 keyword %\[0\s-\+,\]\[0123456789\*\]\[.\]\[0123456789\*\]\[hl\]\{diuxX\} brightgreen
170 keyword %\[hl\]n brightgreen
171 keyword %\[-\]\[0123456789\*\]\[.\]\[0123456789\*\]s brightgreen
172 keyword %[*] brightgreen
173 keyword %c brightgreen
174 keyword %p brightgreen
175 keyword \\\{0123\}\{01234567\}\{01234567\} brightgreen
176 keyword \\\\ brightgreen
177 keyword \\' brightgreen
178 keyword \\\{abtnvfr\} brightgreen