1 /* A Bison parser, made by GNU Bison 3.3.2.  */
2 
3 /* Bison interface for Yacc-like parsers in C
4 
5    Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
6    Inc.
7 
8    This program is free software: you can redistribute it and/or modify
9    it under the terms of the GNU General Public License as published by
10    the Free Software Foundation, either version 3 of the License, or
11    (at your option) any later version.
12 
13    This program is distributed in the hope that it will be useful,
14    but WITHOUT ANY WARRANTY; without even the implied warranty of
15    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16    GNU General Public License for more details.
17 
18    You should have received a copy of the GNU General Public License
19    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
20 
21 /* As a special exception, you may create a larger work that contains
22    part or all of the Bison parser skeleton and distribute that work
23    under terms of your choice, so long as that work isn't itself a
24    parser generator using the skeleton or a modified version thereof
25    as a parser skeleton.  Alternatively, if you modify or redistribute
26    the parser skeleton itself, you may (at your option) remove this
27    special exception, which will cause the skeleton and the resulting
28    Bison output files to be licensed under the GNU General Public
29    License without this special exception.
30 
31    This special exception was added by the Free Software Foundation in
32    version 2.2 of Bison.  */
33 
34 /* Undocumented macros, especially those whose name start with YY_,
35    are private implementation details.  Do not rely on them.  */
36 
37 #ifndef YY_SIEVE_SIEVE_SIEVE_H_INCLUDED
38 # define YY_SIEVE_SIEVE_SIEVE_H_INCLUDED
39 /* Debug traces.  */
40 #ifndef YYDEBUG
41 # define YYDEBUG 0
42 #endif
43 #if YYDEBUG
44 extern int sievedebug;
45 #endif
46 
47 /* Token type.  */
48 #ifndef YYTOKENTYPE
49 # define YYTOKENTYPE
50   enum yytokentype
51   {
52     NUMBER = 258,
53     STRING = 259,
54     IF = 260,
55     ELSIF = 261,
56     ELSE = 262,
57     REQUIRE = 263,
58     STOP = 264,
59     DISCARD = 265,
60     KEEP = 266,
61     FILEINTO = 267,
62     REDIRECT = 268,
63     ANYOF = 269,
64     ALLOF = 270,
65     EXISTS = 271,
66     NOT = 272,
67     SFALSE = 273,
68     STRUE = 274,
69     SIZE = 275,
70     HEADERT = 276,
71     ADDRESS = 277,
72     ENVELOPE = 278,
73     COMPARATOR = 279,
74     OVER = 280,
75     UNDER = 281,
76     ALL = 282,
77     LOCALPART = 283,
78     DOMAIN = 284,
79     IS = 285,
80     CONTAINS = 286,
81     MATCHES = 287,
82     OCTET = 288,
83     ASCIICASEMAP = 289,
84     ASCIINUMERIC = 290,
85     REGEX = 291,
86     QUOTEREGEX = 292,
87     COPY = 293,
88     BODY = 294,
89     RAW = 295,
90     TEXT = 296,
91     CONTENT = 297,
92     ENVIRONMENT = 298,
93     STRINGT = 299,
94     SET = 300,
95     LOWER = 301,
96     UPPER = 302,
97     LOWERFIRST = 303,
98     UPPERFIRST = 304,
99     QUOTEWILDCARD = 305,
100     LENGTH = 306,
101     VACATION = 307,
102     DAYS = 308,
103     SUBJECT = 309,
104     FROM = 310,
105     ADDRESSES = 311,
106     MIME = 312,
107     HANDLE = 313,
108     SECONDS = 314,
109     COUNT = 315,
110     VALUE = 316,
111     GT = 317,
112     GE = 318,
113     LT = 319,
114     LE = 320,
115     EQ = 321,
116     NE = 322,
117     FLAGS = 323,
118     HASFLAG = 324,
119     SETFLAG = 325,
120     ADDFLAG = 326,
121     REMOVEFLAG = 327,
122     MARK = 328,
123     UNMARK = 329,
124     USER = 330,
125     DETAIL = 331,
126     DATE = 332,
127     CURRENTDATE = 333,
128     ORIGINALZONE = 334,
129     ZONE = 335,
130     TIMEZONE = 336,
131     YEARP = 337,
132     MONTHP = 338,
133     DAYP = 339,
134     DATEP = 340,
135     JULIAN = 341,
136     HOURP = 342,
137     MINUTEP = 343,
138     SECONDP = 344,
139     TIMEP = 345,
140     ISO8601 = 346,
141     STD11 = 347,
142     ZONEP = 348,
143     WEEKDAYP = 349,
144     INDEX = 350,
145     LAST = 351,
146     ADDHEADER = 352,
147     DELETEHEADER = 353,
148     REJCT = 354,
149     EREJECT = 355,
150     METHOD = 356,
151     OPTIONS = 357,
152     MESSAGE = 358,
153     IMPORTANCE = 359,
154     VALIDNOTIFYMETHOD = 360,
155     NOTIFYMETHODCAPABILITY = 361,
156     NOTIFY = 362,
157     ENOTIFY = 363,
158     ENCODEURL = 364,
159     DENOTIFY = 365,
160     ID = 366,
161     ANY = 367,
162     LOW = 368,
163     NORMAL = 369,
164     HIGH = 370,
165     IHAVE = 371,
166     ERROR = 372,
167     MAILBOXEXISTS = 373,
168     CREATE = 374,
169     METADATA = 375,
170     METADATAEXISTS = 376,
171     SERVERMETADATA = 377,
172     SERVERMETADATAEXISTS = 378,
173     BYTIMEREL = 379,
174     BYTIMEABS = 380,
175     BYMODE = 381,
176     BYTRACE = 382,
177     DSNNOTIFY = 383,
178     DSNRET = 384,
179     VALIDEXTLIST = 385,
180     LIST = 386,
181     INCLUDE = 387,
182     OPTIONAL = 388,
183     ONCE = 389,
184     RETURN = 390,
185     PERSONAL = 391,
186     GLOBAL = 392,
187     DUPLICATE = 393,
188     HEADER = 394,
189     UNIQUEID = 395,
190     SPECIALUSEEXISTS = 396,
191     SPECIALUSE = 397,
192     FCC = 398,
193     MAILBOXID = 399,
194     MAILBOXIDEXISTS = 400,
195     LOG = 401,
196     JMAPQUERY = 402,
197     SNOOZE = 403,
198     MAILBOX = 404,
199     ADDFLAGS = 405,
200     REMOVEFLAGS = 406,
201     WEEKDAYS = 407
202   };
203 #endif
204 /* Tokens.  */
205 #define NUMBER 258
206 #define STRING 259
207 #define IF 260
208 #define ELSIF 261
209 #define ELSE 262
210 #define REQUIRE 263
211 #define STOP 264
212 #define DISCARD 265
213 #define KEEP 266
214 #define FILEINTO 267
215 #define REDIRECT 268
216 #define ANYOF 269
217 #define ALLOF 270
218 #define EXISTS 271
219 #define NOT 272
220 #define SFALSE 273
221 #define STRUE 274
222 #define SIZE 275
223 #define HEADERT 276
224 #define ADDRESS 277
225 #define ENVELOPE 278
226 #define COMPARATOR 279
227 #define OVER 280
228 #define UNDER 281
229 #define ALL 282
230 #define LOCALPART 283
231 #define DOMAIN 284
232 #define IS 285
233 #define CONTAINS 286
234 #define MATCHES 287
235 #define OCTET 288
236 #define ASCIICASEMAP 289
237 #define ASCIINUMERIC 290
238 #define REGEX 291
239 #define QUOTEREGEX 292
240 #define COPY 293
241 #define BODY 294
242 #define RAW 295
243 #define TEXT 296
244 #define CONTENT 297
245 #define ENVIRONMENT 298
246 #define STRINGT 299
247 #define SET 300
248 #define LOWER 301
249 #define UPPER 302
250 #define LOWERFIRST 303
251 #define UPPERFIRST 304
252 #define QUOTEWILDCARD 305
253 #define LENGTH 306
254 #define VACATION 307
255 #define DAYS 308
256 #define SUBJECT 309
257 #define FROM 310
258 #define ADDRESSES 311
259 #define MIME 312
260 #define HANDLE 313
261 #define SECONDS 314
262 #define COUNT 315
263 #define VALUE 316
264 #define GT 317
265 #define GE 318
266 #define LT 319
267 #define LE 320
268 #define EQ 321
269 #define NE 322
270 #define FLAGS 323
271 #define HASFLAG 324
272 #define SETFLAG 325
273 #define ADDFLAG 326
274 #define REMOVEFLAG 327
275 #define MARK 328
276 #define UNMARK 329
277 #define USER 330
278 #define DETAIL 331
279 #define DATE 332
280 #define CURRENTDATE 333
281 #define ORIGINALZONE 334
282 #define ZONE 335
283 #define TIMEZONE 336
284 #define YEARP 337
285 #define MONTHP 338
286 #define DAYP 339
287 #define DATEP 340
288 #define JULIAN 341
289 #define HOURP 342
290 #define MINUTEP 343
291 #define SECONDP 344
292 #define TIMEP 345
293 #define ISO8601 346
294 #define STD11 347
295 #define ZONEP 348
296 #define WEEKDAYP 349
297 #define INDEX 350
298 #define LAST 351
299 #define ADDHEADER 352
300 #define DELETEHEADER 353
301 #define REJCT 354
302 #define EREJECT 355
303 #define METHOD 356
304 #define OPTIONS 357
305 #define MESSAGE 358
306 #define IMPORTANCE 359
307 #define VALIDNOTIFYMETHOD 360
308 #define NOTIFYMETHODCAPABILITY 361
309 #define NOTIFY 362
310 #define ENOTIFY 363
311 #define ENCODEURL 364
312 #define DENOTIFY 365
313 #define ID 366
314 #define ANY 367
315 #define LOW 368
316 #define NORMAL 369
317 #define HIGH 370
318 #define IHAVE 371
319 #define ERROR 372
320 #define MAILBOXEXISTS 373
321 #define CREATE 374
322 #define METADATA 375
323 #define METADATAEXISTS 376
324 #define SERVERMETADATA 377
325 #define SERVERMETADATAEXISTS 378
326 #define BYTIMEREL 379
327 #define BYTIMEABS 380
328 #define BYMODE 381
329 #define BYTRACE 382
330 #define DSNNOTIFY 383
331 #define DSNRET 384
332 #define VALIDEXTLIST 385
333 #define LIST 386
334 #define INCLUDE 387
335 #define OPTIONAL 388
336 #define ONCE 389
337 #define RETURN 390
338 #define PERSONAL 391
339 #define GLOBAL 392
340 #define DUPLICATE 393
341 #define HEADER 394
342 #define UNIQUEID 395
343 #define SPECIALUSEEXISTS 396
344 #define SPECIALUSE 397
345 #define FCC 398
346 #define MAILBOXID 399
347 #define MAILBOXIDEXISTS 400
348 #define LOG 401
349 #define JMAPQUERY 402
350 #define SNOOZE 403
351 #define MAILBOX 404
352 #define ADDFLAGS 405
353 #define REMOVEFLAGS 406
354 #define WEEKDAYS 407
355 
356 /* Value type.  */
357 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
358 
359 union YYSTYPE
360 {
361 #line 170 "sieve/sieve.y" /* yacc.c:1921  */
362 
363     int nval;
364     char *sval;
365     arrayu64_t *nl;
366     strarray_t *sl;
367     comp_t *ctag;
368     test_t *test;
369     testlist_t *testl;
370     commandlist_t *cl;
371 
372 #line 373 "sieve/sieve.h" /* yacc.c:1921  */
373 };
374 
375 typedef union YYSTYPE YYSTYPE;
376 # define YYSTYPE_IS_TRIVIAL 1
377 # define YYSTYPE_IS_DECLARED 1
378 #endif
379 
380 
381 
382 int sieveparse (sieve_script_t *sscript);
383 
384 #endif /* !YY_SIEVE_SIEVE_SIEVE_H_INCLUDED  */
385