Coverage Report

Created: 2026-12-01 06:07

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/libpcap/build/grammar.c
Line
Count
Source
1
/* A Bison parser, made by GNU Bison 3.8.2.  */
2
3
/* Bison implementation for Yacc-like parsers in C
4
5
   Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 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 <https://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
/* C LALR(1) parser skeleton written by Richard Stallman, by
35
   simplifying the original so-called "semantic" parser.  */
36
37
/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual,
38
   especially those whose name start with YY_ or yy_.  They are
39
   private implementation details that can be changed or removed.  */
40
41
/* All symbols defined below should begin with yy or YY, to avoid
42
   infringing on user name space.  This should be done even for local
43
   variables, as they might otherwise be expanded by user macros.
44
   There are some unavoidable exceptions within include files to
45
   define necessary library symbols; they are noted "INFRINGES ON
46
   USER NAME SPACE" below.  */
47
48
/* Identify Bison output, and Bison version.  */
49
#define YYBISON 30802
50
51
/* Bison version string.  */
52
#define YYBISON_VERSION "3.8.2"
53
54
/* Skeleton name.  */
55
#define YYSKELETON_NAME "yacc.c"
56
57
/* Pure parsers.  */
58
#define YYPURE 1
59
60
/* Push parsers.  */
61
#define YYPUSH 0
62
63
/* Pull parsers.  */
64
#define YYPULL 1
65
66
67
/* Substitute the variable and function names.  */
68
#define yyparse         pcap_parse
69
0
#define yylex           pcap_lex
70
0
#define yyerror         pcap_error
71
#define yydebug         pcap_debug
72
0
#define yynerrs         pcap_nerrs
73
74
/* First part of user prologue.  */
75
#line 47 "/src/libpcap/build/grammar.y"
76
77
/*
78
 * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996
79
 *  The Regents of the University of California.  All rights reserved.
80
 *
81
 * Redistribution and use in source and binary forms, with or without
82
 * modification, are permitted provided that: (1) source code distributions
83
 * retain the above copyright notice and this paragraph in its entirety, (2)
84
 * distributions including binary code include the above copyright notice and
85
 * this paragraph in its entirety in the documentation or other materials
86
 * provided with the distribution, and (3) all advertising materials mentioning
87
 * features or use of this software display the following acknowledgement:
88
 * ``This product includes software developed by the University of California,
89
 * Lawrence Berkeley Laboratory and its contributors.'' Neither the name of
90
 * the University nor the names of its contributors may be used to endorse
91
 * or promote products derived from this software without specific prior
92
 * written permission.
93
 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
94
 * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
95
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
96
 *
97
 */
98
99
#include <config.h>
100
101
/*
102
 * grammar.h requires gencode.h and sometimes breaks in a polluted namespace
103
 * (see ftmacros.h), so include it early.
104
 */
105
#include "gencode.h"
106
#include "grammar.h"
107
108
#include <stdlib.h>
109
110
#include <stdio.h>
111
112
#include "diag-control.h"
113
114
#include "pcap-int.h"
115
116
#include "scanner.h"
117
118
#include "llc.h"
119
#include "ieee80211.h"
120
#include "pflog.h"
121
#include <pcap/namedb.h>
122
123
#ifdef HAVE_OS_PROTO_H
124
#include "os-proto.h"
125
#endif
126
127
/*
128
 * Work around some bugs in Berkeley YACC prior to the 2017-07-09
129
 * release.
130
 *
131
 * The 2005-05-05 release was the first one to define YYPATCH, so
132
 * we treat any release that either 1) doesn't define YYPATCH or
133
 * 2) defines it to a value < 20170709 as being buggy.
134
 */
135
#if defined(YYBYACC) && (!defined(YYPATCH) || YYPATCH < 20170709)
136
/*
137
 * Both Berkeley YACC and Bison define yydebug (under whatever name
138
 * it has) as a global, but Bison does so only if YYDEBUG is defined.
139
 * Berkeley YACC, prior to the 2017-07-09 release, defines it even if
140
 * YYDEBUG isn't defined; declare it here to suppress a warning.  The
141
 * 2017-07-09 release fixes that.
142
 */
143
#if !defined(YYDEBUG)
144
extern int yydebug;
145
#endif
146
147
/*
148
 * In Berkeley YACC, prior to the 2017-07-09 release, yynerrs (under
149
 * whatever name it has) is global, even if it's building a reentrant
150
 * parser.  In Bison, and in the Berkeley YACC 2017-07-09 release and
151
 * later, it's local in reentrant parsers.
152
 *
153
 * Declare it to squelch a warning.
154
 */
155
extern int yynerrs;
156
#endif
157
158
0
#define QSET(q, p, d, a) (q).proto = (unsigned char)(p),\
159
0
       (q).dir = (unsigned char)(d),\
160
0
       (q).addr = (unsigned char)(a)
161
162
struct tok {
163
  int v;      /* value */
164
  const char *s;    /* string */
165
};
166
167
static const struct tok ieee80211_types[] = {
168
  { IEEE80211_FC0_TYPE_DATA, "data" },
169
  { IEEE80211_FC0_TYPE_MGT, "mgt" },
170
  { IEEE80211_FC0_TYPE_MGT, "management" },
171
  { IEEE80211_FC0_TYPE_CTL, "ctl" },
172
  { IEEE80211_FC0_TYPE_CTL, "control" },
173
  { 0, NULL }
174
};
175
static const struct tok ieee80211_mgt_subtypes[] = {
176
  { IEEE80211_FC0_SUBTYPE_ASSOC_REQ, "assocreq" },
177
  { IEEE80211_FC0_SUBTYPE_ASSOC_REQ, "assoc-req" },
178
  { IEEE80211_FC0_SUBTYPE_ASSOC_RESP, "assocresp" },
179
  { IEEE80211_FC0_SUBTYPE_ASSOC_RESP, "assoc-resp" },
180
  { IEEE80211_FC0_SUBTYPE_REASSOC_REQ, "reassocreq" },
181
  { IEEE80211_FC0_SUBTYPE_REASSOC_REQ, "reassoc-req" },
182
  { IEEE80211_FC0_SUBTYPE_REASSOC_RESP, "reassocresp" },
183
  { IEEE80211_FC0_SUBTYPE_REASSOC_RESP, "reassoc-resp" },
184
  { IEEE80211_FC0_SUBTYPE_PROBE_REQ, "probereq" },
185
  { IEEE80211_FC0_SUBTYPE_PROBE_REQ, "probe-req" },
186
  { IEEE80211_FC0_SUBTYPE_PROBE_RESP, "proberesp" },
187
  { IEEE80211_FC0_SUBTYPE_PROBE_RESP, "probe-resp" },
188
  { IEEE80211_FC0_SUBTYPE_BEACON, "beacon" },
189
  { IEEE80211_FC0_SUBTYPE_ATIM, "atim" },
190
  { IEEE80211_FC0_SUBTYPE_DISASSOC, "disassoc" },
191
  { IEEE80211_FC0_SUBTYPE_DISASSOC, "disassociation" },
192
  { IEEE80211_FC0_SUBTYPE_AUTH, "auth" },
193
  { IEEE80211_FC0_SUBTYPE_AUTH, "authentication" },
194
  { IEEE80211_FC0_SUBTYPE_DEAUTH, "deauth" },
195
  { IEEE80211_FC0_SUBTYPE_DEAUTH, "deauthentication" },
196
  { 0, NULL }
197
};
198
static const struct tok ieee80211_ctl_subtypes[] = {
199
  { IEEE80211_FC0_SUBTYPE_BAR, "bar" },
200
  { IEEE80211_FC0_SUBTYPE_BA, "ba" },
201
  { IEEE80211_FC0_SUBTYPE_PS_POLL, "ps-poll" },
202
  { IEEE80211_FC0_SUBTYPE_RTS, "rts" },
203
  { IEEE80211_FC0_SUBTYPE_CTS, "cts" },
204
  { IEEE80211_FC0_SUBTYPE_ACK, "ack" },
205
  { IEEE80211_FC0_SUBTYPE_CF_END, "cf-end" },
206
  { IEEE80211_FC0_SUBTYPE_CF_END_ACK, "cf-end-ack" },
207
  { 0, NULL }
208
};
209
static const struct tok ieee80211_data_subtypes[] = {
210
  { IEEE80211_FC0_SUBTYPE_DATA, "data" },
211
  { IEEE80211_FC0_SUBTYPE_CF_ACK, "data-cf-ack" },
212
  { IEEE80211_FC0_SUBTYPE_CF_POLL, "data-cf-poll" },
213
  { IEEE80211_FC0_SUBTYPE_CF_ACPL, "data-cf-ack-poll" },
214
  { IEEE80211_FC0_SUBTYPE_NODATA, "null" },
215
  { IEEE80211_FC0_SUBTYPE_NODATA_CF_ACK, "cf-ack" },
216
  { IEEE80211_FC0_SUBTYPE_NODATA_CF_POLL, "cf-poll"  },
217
  { IEEE80211_FC0_SUBTYPE_NODATA_CF_ACPL, "cf-ack-poll" },
218
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_DATA, "qos-data" },
219
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_CF_ACK, "qos-data-cf-ack" },
220
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_CF_POLL, "qos-data-cf-poll" },
221
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_CF_ACPL, "qos-data-cf-ack-poll" },
222
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_NODATA, "qos" },
223
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_NODATA_CF_POLL, "qos-cf-poll" },
224
  { IEEE80211_FC0_SUBTYPE_QOS|IEEE80211_FC0_SUBTYPE_NODATA_CF_ACPL, "qos-cf-ack-poll" },
225
  { 0, NULL }
226
};
227
static const struct tok llc_s_subtypes[] = {
228
  { LLC_RR, "rr" },
229
  { LLC_RNR, "rnr" },
230
  { LLC_REJ, "rej" },
231
  { 0, NULL }
232
};
233
static const struct tok llc_u_subtypes[] = {
234
  { LLC_UI, "ui" },
235
  { LLC_UA, "ua" },
236
  { LLC_DISC, "disc" },
237
  { LLC_DM, "dm" },
238
  { LLC_SABME, "sabme" },
239
  { LLC_TEST, "test" },
240
  { LLC_XID, "xid" },
241
  { LLC_FRMR, "frmr" },
242
  { 0, NULL }
243
};
244
struct type2tok {
245
  int type;
246
  const struct tok *tok;
247
};
248
static const struct type2tok ieee80211_type_subtypes[] = {
249
  { IEEE80211_FC0_TYPE_MGT, ieee80211_mgt_subtypes },
250
  { IEEE80211_FC0_TYPE_CTL, ieee80211_ctl_subtypes },
251
  { IEEE80211_FC0_TYPE_DATA, ieee80211_data_subtypes },
252
  { 0, NULL }
253
};
254
255
static int
256
str2tok(const char *str, const struct tok *toks)
257
0
{
258
0
  int i;
259
260
0
  for (i = 0; toks[i].s != NULL; i++) {
261
0
    if (pcapint_strcasecmp(toks[i].s, str) == 0) {
262
      /*
263
       * Just in case somebody is using this to
264
       * generate values of -1/0xFFFFFFFF.
265
       * That won't work, as it's indistinguishable
266
       * from an error.
267
       */
268
0
      if (toks[i].v == -1)
269
0
        abort();
270
0
      return (toks[i].v);
271
0
    }
272
0
  }
273
0
  return (-1);
274
0
}
275
276
static const struct qual qerr = { Q_UNDEF, Q_UNDEF, Q_UNDEF, Q_UNDEF };
277
278
static void
279
yyerror(void *yyscanner _U_, compiler_state_t *cstate, const char *msg)
280
0
{
281
0
  bpf_set_error(cstate, "can't parse filter expression: %s", msg);
282
0
}
283
284
static const struct tok pflog_reasons[] = {
285
  { PFRES_MATCH,    "match" },
286
  { PFRES_BADOFF,   "bad-offset" },
287
  { PFRES_FRAG,   "fragment" },
288
  { PFRES_SHORT,    "short" },
289
  { PFRES_NORM,   "normalize" },
290
  { PFRES_MEMORY,   "memory" },
291
  { PFRES_TS,   "bad-timestamp" },
292
  { PFRES_CONGEST,  "congestion" },
293
  { PFRES_IPOPTIONS,  "ip-option" },
294
  { PFRES_PROTCKSUM,  "proto-cksum" },
295
  { PFRES_BADSTATE, "state-mismatch" },
296
  { PFRES_STATEINS, "state-insert" },
297
  { PFRES_MAXSTATES,  "state-limit" },
298
  { PFRES_SRCLIMIT, "src-limit" },
299
  { PFRES_SYNPROXY, "synproxy" },
300
#if defined(__FreeBSD__)
301
  { PFRES_MAPFAILED,  "map-failed" },
302
#elif defined(__NetBSD__)
303
  { PFRES_STATELOCKED,  "state-locked" },
304
#elif defined(__OpenBSD__)
305
  { PFRES_TRANSLATE,  "translate" },
306
  { PFRES_NOROUTE,  "no-route" },
307
#elif defined(__APPLE__)
308
  { PFRES_DUMMYNET, "dummynet" },
309
#endif
310
  { 0, NULL }
311
};
312
313
static int
314
pfreason_to_num(compiler_state_t *cstate, const char *reason)
315
0
{
316
0
  int i;
317
318
0
  i = str2tok(reason, pflog_reasons);
319
0
  if (i == -1)
320
0
    bpf_set_error(cstate, "unknown PF reason \"%s\"", reason);
321
0
  return (i);
322
0
}
323
324
static const struct tok pflog_actions[] = {
325
  { PF_PASS,    "pass" },
326
  { PF_PASS,    "accept" }, /* alias for "pass" */
327
  { PF_DROP,    "drop" },
328
  { PF_DROP,    "block" },  /* alias for "drop" */
329
  { PF_SCRUB,   "scrub" },
330
  { PF_NOSCRUB,   "noscrub" },
331
  { PF_NAT,   "nat" },
332
  { PF_NONAT,   "nonat" },
333
  { PF_BINAT,   "binat" },
334
  { PF_NOBINAT,   "nobinat" },
335
  { PF_RDR,   "rdr" },
336
  { PF_NORDR,   "nordr" },
337
  { PF_SYNPROXY_DROP, "synproxy-drop" },
338
#if defined(__FreeBSD__)
339
  { PF_DEFER,   "defer" },
340
#elif defined(__OpenBSD__)
341
  { PF_DEFER,   "defer" },
342
  { PF_MATCH,   "match" },
343
  { PF_DIVERT,    "divert" },
344
  { PF_RT,    "rt" },
345
  { PF_AFRT,    "afrt" },
346
#elif defined(__APPLE__)
347
  { PF_DUMMYNET,    "dummynet" },
348
  { PF_NODUMMYNET,  "nodummynet" },
349
  { PF_NAT64,   "nat64" },
350
  { PF_NONAT64,   "nonat64" },
351
#endif
352
  { 0, NULL },
353
};
354
355
static int
356
pfaction_to_num(compiler_state_t *cstate, const char *action)
357
0
{
358
0
  int i;
359
360
0
  i = str2tok(action, pflog_actions);
361
0
  if (i == -1)
362
0
    bpf_set_error(cstate, "unknown PF action \"%s\"", action);
363
0
  return (i);
364
0
}
365
366
/*
367
 * For calls that might return an "an error occurred" value.
368
 */
369
0
#define CHECK_INT_VAL(val)  if (val == -1) YYABORT
370
0
#define CHECK_PTR_VAL(val)  if (val == NULL) YYABORT
371
372
DIAG_OFF_BISON_BYACC
373
374
#line 375 "/src/libpcap/build/grammar.c"
375
376
# ifndef YY_CAST
377
#  ifdef __cplusplus
378
#   define YY_CAST(Type, Val) static_cast<Type> (Val)
379
#   define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast<Type> (Val)
380
#  else
381
0
#   define YY_CAST(Type, Val) ((Type) (Val))
382
#   define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val))
383
#  endif
384
# endif
385
# ifndef YY_NULLPTR
386
#  if defined __cplusplus
387
#   if 201103L <= __cplusplus
388
#    define YY_NULLPTR nullptr
389
#   else
390
#    define YY_NULLPTR 0
391
#   endif
392
#  else
393
#   define YY_NULLPTR ((void*)0)
394
#  endif
395
# endif
396
397
#include "grammar.h"
398
/* Symbol kind.  */
399
enum yysymbol_kind_t
400
{
401
  YYSYMBOL_YYEMPTY = -2,
402
  YYSYMBOL_YYEOF = 0,                      /* "end of file"  */
403
  YYSYMBOL_YYerror = 1,                    /* error  */
404
  YYSYMBOL_YYUNDEF = 2,                    /* "invalid token"  */
405
  YYSYMBOL_DST = 3,                        /* DST  */
406
  YYSYMBOL_SRC = 4,                        /* SRC  */
407
  YYSYMBOL_HOST = 5,                       /* HOST  */
408
  YYSYMBOL_GATEWAY = 6,                    /* GATEWAY  */
409
  YYSYMBOL_NET = 7,                        /* NET  */
410
  YYSYMBOL_NETMASK = 8,                    /* NETMASK  */
411
  YYSYMBOL_PORT = 9,                       /* PORT  */
412
  YYSYMBOL_PORTRANGE = 10,                 /* PORTRANGE  */
413
  YYSYMBOL_LESS = 11,                      /* LESS  */
414
  YYSYMBOL_GREATER = 12,                   /* GREATER  */
415
  YYSYMBOL_PROTO = 13,                     /* PROTO  */
416
  YYSYMBOL_PROTOCHAIN = 14,                /* PROTOCHAIN  */
417
  YYSYMBOL_CBYTE = 15,                     /* CBYTE  */
418
  YYSYMBOL_ARP = 16,                       /* ARP  */
419
  YYSYMBOL_RARP = 17,                      /* RARP  */
420
  YYSYMBOL_IP = 18,                        /* IP  */
421
  YYSYMBOL_SCTP = 19,                      /* SCTP  */
422
  YYSYMBOL_TCP = 20,                       /* TCP  */
423
  YYSYMBOL_UDP = 21,                       /* UDP  */
424
  YYSYMBOL_ICMP = 22,                      /* ICMP  */
425
  YYSYMBOL_IGMP = 23,                      /* IGMP  */
426
  YYSYMBOL_IGRP = 24,                      /* IGRP  */
427
  YYSYMBOL_PIM = 25,                       /* PIM  */
428
  YYSYMBOL_VRRP = 26,                      /* VRRP  */
429
  YYSYMBOL_CARP = 27,                      /* CARP  */
430
  YYSYMBOL_ATALK = 28,                     /* ATALK  */
431
  YYSYMBOL_AARP = 29,                      /* AARP  */
432
  YYSYMBOL_DECNET = 30,                    /* DECNET  */
433
  YYSYMBOL_LAT = 31,                       /* LAT  */
434
  YYSYMBOL_SCA = 32,                       /* SCA  */
435
  YYSYMBOL_MOPRC = 33,                     /* MOPRC  */
436
  YYSYMBOL_MOPDL = 34,                     /* MOPDL  */
437
  YYSYMBOL_TK_BROADCAST = 35,              /* TK_BROADCAST  */
438
  YYSYMBOL_TK_MULTICAST = 36,              /* TK_MULTICAST  */
439
  YYSYMBOL_NUM = 37,                       /* NUM  */
440
  YYSYMBOL_INBOUND = 38,                   /* INBOUND  */
441
  YYSYMBOL_OUTBOUND = 39,                  /* OUTBOUND  */
442
  YYSYMBOL_IFINDEX = 40,                   /* IFINDEX  */
443
  YYSYMBOL_PF_IFNAME = 41,                 /* PF_IFNAME  */
444
  YYSYMBOL_PF_RSET = 42,                   /* PF_RSET  */
445
  YYSYMBOL_PF_RNR = 43,                    /* PF_RNR  */
446
  YYSYMBOL_PF_SRNR = 44,                   /* PF_SRNR  */
447
  YYSYMBOL_PF_REASON = 45,                 /* PF_REASON  */
448
  YYSYMBOL_PF_ACTION = 46,                 /* PF_ACTION  */
449
  YYSYMBOL_TYPE = 47,                      /* TYPE  */
450
  YYSYMBOL_SUBTYPE = 48,                   /* SUBTYPE  */
451
  YYSYMBOL_DIR = 49,                       /* DIR  */
452
  YYSYMBOL_ADDR1 = 50,                     /* ADDR1  */
453
  YYSYMBOL_ADDR2 = 51,                     /* ADDR2  */
454
  YYSYMBOL_ADDR3 = 52,                     /* ADDR3  */
455
  YYSYMBOL_ADDR4 = 53,                     /* ADDR4  */
456
  YYSYMBOL_RA = 54,                        /* RA  */
457
  YYSYMBOL_TA = 55,                        /* TA  */
458
  YYSYMBOL_LINK = 56,                      /* LINK  */
459
  YYSYMBOL_GEQ = 57,                       /* GEQ  */
460
  YYSYMBOL_LEQ = 58,                       /* LEQ  */
461
  YYSYMBOL_NEQ = 59,                       /* NEQ  */
462
  YYSYMBOL_ID = 60,                        /* ID  */
463
  YYSYMBOL_EID = 61,                       /* EID  */
464
  YYSYMBOL_HID = 62,                       /* HID  */
465
  YYSYMBOL_HID6 = 63,                      /* HID6  */
466
  YYSYMBOL_AID = 64,                       /* AID  */
467
  YYSYMBOL_LSH = 65,                       /* LSH  */
468
  YYSYMBOL_RSH = 66,                       /* RSH  */
469
  YYSYMBOL_LEN = 67,                       /* LEN  */
470
  YYSYMBOL_IPV6 = 68,                      /* IPV6  */
471
  YYSYMBOL_ICMPV6 = 69,                    /* ICMPV6  */
472
  YYSYMBOL_AH = 70,                        /* AH  */
473
  YYSYMBOL_ESP = 71,                       /* ESP  */
474
  YYSYMBOL_VLAN = 72,                      /* VLAN  */
475
  YYSYMBOL_MPLS = 73,                      /* MPLS  */
476
  YYSYMBOL_PPPOED = 74,                    /* PPPOED  */
477
  YYSYMBOL_PPPOES = 75,                    /* PPPOES  */
478
  YYSYMBOL_GENEVE = 76,                    /* GENEVE  */
479
  YYSYMBOL_VXLAN = 77,                     /* VXLAN  */
480
  YYSYMBOL_ISO = 78,                       /* ISO  */
481
  YYSYMBOL_ESIS = 79,                      /* ESIS  */
482
  YYSYMBOL_CLNP = 80,                      /* CLNP  */
483
  YYSYMBOL_ISIS = 81,                      /* ISIS  */
484
  YYSYMBOL_L1 = 82,                        /* L1  */
485
  YYSYMBOL_L2 = 83,                        /* L2  */
486
  YYSYMBOL_IIH = 84,                       /* IIH  */
487
  YYSYMBOL_LSP = 85,                       /* LSP  */
488
  YYSYMBOL_SNP = 86,                       /* SNP  */
489
  YYSYMBOL_CSNP = 87,                      /* CSNP  */
490
  YYSYMBOL_PSNP = 88,                      /* PSNP  */
491
  YYSYMBOL_STP = 89,                       /* STP  */
492
  YYSYMBOL_IPX = 90,                       /* IPX  */
493
  YYSYMBOL_NETBEUI = 91,                   /* NETBEUI  */
494
  YYSYMBOL_LANE = 92,                      /* LANE  */
495
  YYSYMBOL_LLC = 93,                       /* LLC  */
496
  YYSYMBOL_METAC = 94,                     /* METAC  */
497
  YYSYMBOL_BCC = 95,                       /* BCC  */
498
  YYSYMBOL_SC = 96,                        /* SC  */
499
  YYSYMBOL_ILMIC = 97,                     /* ILMIC  */
500
  YYSYMBOL_OAMF4EC = 98,                   /* OAMF4EC  */
501
  YYSYMBOL_OAMF4SC = 99,                   /* OAMF4SC  */
502
  YYSYMBOL_OAM = 100,                      /* OAM  */
503
  YYSYMBOL_OAMF4 = 101,                    /* OAMF4  */
504
  YYSYMBOL_CONNECTMSG = 102,               /* CONNECTMSG  */
505
  YYSYMBOL_METACONNECT = 103,              /* METACONNECT  */
506
  YYSYMBOL_VPI = 104,                      /* VPI  */
507
  YYSYMBOL_VCI = 105,                      /* VCI  */
508
  YYSYMBOL_RADIO = 106,                    /* RADIO  */
509
  YYSYMBOL_FISU = 107,                     /* FISU  */
510
  YYSYMBOL_LSSU = 108,                     /* LSSU  */
511
  YYSYMBOL_MSU = 109,                      /* MSU  */
512
  YYSYMBOL_HFISU = 110,                    /* HFISU  */
513
  YYSYMBOL_HLSSU = 111,                    /* HLSSU  */
514
  YYSYMBOL_HMSU = 112,                     /* HMSU  */
515
  YYSYMBOL_SIO = 113,                      /* SIO  */
516
  YYSYMBOL_OPC = 114,                      /* OPC  */
517
  YYSYMBOL_DPC = 115,                      /* DPC  */
518
  YYSYMBOL_SLS = 116,                      /* SLS  */
519
  YYSYMBOL_HSIO = 117,                     /* HSIO  */
520
  YYSYMBOL_HOPC = 118,                     /* HOPC  */
521
  YYSYMBOL_HDPC = 119,                     /* HDPC  */
522
  YYSYMBOL_HSLS = 120,                     /* HSLS  */
523
  YYSYMBOL_LEX_ERROR = 121,                /* LEX_ERROR  */
524
  YYSYMBOL_OR = 122,                       /* OR  */
525
  YYSYMBOL_AND = 123,                      /* AND  */
526
  YYSYMBOL_124_ = 124,                     /* '!'  */
527
  YYSYMBOL_125_ = 125,                     /* '|'  */
528
  YYSYMBOL_126_ = 126,                     /* '&'  */
529
  YYSYMBOL_127_ = 127,                     /* '+'  */
530
  YYSYMBOL_128_ = 128,                     /* '-'  */
531
  YYSYMBOL_129_ = 129,                     /* '*'  */
532
  YYSYMBOL_130_ = 130,                     /* '/'  */
533
  YYSYMBOL_UMINUS = 131,                   /* UMINUS  */
534
  YYSYMBOL_132_ = 132,                     /* ')'  */
535
  YYSYMBOL_133_ = 133,                     /* '('  */
536
  YYSYMBOL_134_ = 134,                     /* '>'  */
537
  YYSYMBOL_135_ = 135,                     /* '='  */
538
  YYSYMBOL_136_ = 136,                     /* '<'  */
539
  YYSYMBOL_137_ = 137,                     /* '['  */
540
  YYSYMBOL_138_ = 138,                     /* ']'  */
541
  YYSYMBOL_139_ = 139,                     /* ':'  */
542
  YYSYMBOL_140_ = 140,                     /* '%'  */
543
  YYSYMBOL_141_ = 141,                     /* '^'  */
544
  YYSYMBOL_YYACCEPT = 142,                 /* $accept  */
545
  YYSYMBOL_prog = 143,                     /* prog  */
546
  YYSYMBOL_null = 144,                     /* null  */
547
  YYSYMBOL_expr = 145,                     /* expr  */
548
  YYSYMBOL_and = 146,                      /* and  */
549
  YYSYMBOL_or = 147,                       /* or  */
550
  YYSYMBOL_id = 148,                       /* id  */
551
  YYSYMBOL_nid = 149,                      /* nid  */
552
  YYSYMBOL_not = 150,                      /* not  */
553
  YYSYMBOL_paren = 151,                    /* paren  */
554
  YYSYMBOL_pid = 152,                      /* pid  */
555
  YYSYMBOL_qid = 153,                      /* qid  */
556
  YYSYMBOL_term = 154,                     /* term  */
557
  YYSYMBOL_head = 155,                     /* head  */
558
  YYSYMBOL_rterm = 156,                    /* rterm  */
559
  YYSYMBOL_pqual = 157,                    /* pqual  */
560
  YYSYMBOL_dqual = 158,                    /* dqual  */
561
  YYSYMBOL_aqual = 159,                    /* aqual  */
562
  YYSYMBOL_ndaqual = 160,                  /* ndaqual  */
563
  YYSYMBOL_pname = 161,                    /* pname  */
564
  YYSYMBOL_other = 162,                    /* other  */
565
  YYSYMBOL_pfvar = 163,                    /* pfvar  */
566
  YYSYMBOL_p80211 = 164,                   /* p80211  */
567
  YYSYMBOL_type = 165,                     /* type  */
568
  YYSYMBOL_subtype = 166,                  /* subtype  */
569
  YYSYMBOL_type_subtype = 167,             /* type_subtype  */
570
  YYSYMBOL_pllc = 168,                     /* pllc  */
571
  YYSYMBOL_dir = 169,                      /* dir  */
572
  YYSYMBOL_reason = 170,                   /* reason  */
573
  YYSYMBOL_action = 171,                   /* action  */
574
  YYSYMBOL_relop = 172,                    /* relop  */
575
  YYSYMBOL_irelop = 173,                   /* irelop  */
576
  YYSYMBOL_arth = 174,                     /* arth  */
577
  YYSYMBOL_narth = 175,                    /* narth  */
578
  YYSYMBOL_byteop = 176,                   /* byteop  */
579
  YYSYMBOL_pnum = 177,                     /* pnum  */
580
  YYSYMBOL_atmtype = 178,                  /* atmtype  */
581
  YYSYMBOL_atmmultitype = 179,             /* atmmultitype  */
582
  YYSYMBOL_atmfield = 180,                 /* atmfield  */
583
  YYSYMBOL_atmvalue = 181,                 /* atmvalue  */
584
  YYSYMBOL_atmfieldvalue = 182,            /* atmfieldvalue  */
585
  YYSYMBOL_atmlistvalue = 183,             /* atmlistvalue  */
586
  YYSYMBOL_mtp2type = 184,                 /* mtp2type  */
587
  YYSYMBOL_mtp3field = 185,                /* mtp3field  */
588
  YYSYMBOL_mtp3value = 186,                /* mtp3value  */
589
  YYSYMBOL_mtp3fieldvalue = 187,           /* mtp3fieldvalue  */
590
  YYSYMBOL_mtp3listvalue = 188             /* mtp3listvalue  */
591
};
592
typedef enum yysymbol_kind_t yysymbol_kind_t;
593
594
595
596
597
#ifdef short
598
# undef short
599
#endif
600
601
/* On compilers that do not define __PTRDIFF_MAX__ etc., make sure
602
   <limits.h> and (if available) <stdint.h> are included
603
   so that the code can choose integer types of a good width.  */
604
605
#ifndef __PTRDIFF_MAX__
606
# include <limits.h> /* INFRINGES ON USER NAME SPACE */
607
# if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
608
#  include <stdint.h> /* INFRINGES ON USER NAME SPACE */
609
#  define YY_STDINT_H
610
# endif
611
#endif
612
613
/* Narrow types that promote to a signed type and that can represent a
614
   signed or unsigned integer of at least N bits.  In tables they can
615
   save space and decrease cache pressure.  Promoting to a signed type
616
   helps avoid bugs in integer arithmetic.  */
617
618
#ifdef __INT_LEAST8_MAX__
619
typedef __INT_LEAST8_TYPE__ yytype_int8;
620
#elif defined YY_STDINT_H
621
typedef int_least8_t yytype_int8;
622
#else
623
typedef signed char yytype_int8;
624
#endif
625
626
#ifdef __INT_LEAST16_MAX__
627
typedef __INT_LEAST16_TYPE__ yytype_int16;
628
#elif defined YY_STDINT_H
629
typedef int_least16_t yytype_int16;
630
#else
631
typedef short yytype_int16;
632
#endif
633
634
/* Work around bug in HP-UX 11.23, which defines these macros
635
   incorrectly for preprocessor constants.  This workaround can likely
636
   be removed in 2023, as HPE has promised support for HP-UX 11.23
637
   (aka HP-UX 11i v2) only through the end of 2022; see Table 2 of
638
   <https://h20195.www2.hpe.com/V2/getpdf.aspx/4AA4-7673ENW.pdf>.  */
639
#ifdef __hpux
640
# undef UINT_LEAST8_MAX
641
# undef UINT_LEAST16_MAX
642
# define UINT_LEAST8_MAX 255
643
# define UINT_LEAST16_MAX 65535
644
#endif
645
646
#if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__
647
typedef __UINT_LEAST8_TYPE__ yytype_uint8;
648
#elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \
649
       && UINT_LEAST8_MAX <= INT_MAX)
650
typedef uint_least8_t yytype_uint8;
651
#elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX
652
typedef unsigned char yytype_uint8;
653
#else
654
typedef short yytype_uint8;
655
#endif
656
657
#if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__
658
typedef __UINT_LEAST16_TYPE__ yytype_uint16;
659
#elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \
660
       && UINT_LEAST16_MAX <= INT_MAX)
661
typedef uint_least16_t yytype_uint16;
662
#elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX
663
typedef unsigned short yytype_uint16;
664
#else
665
typedef int yytype_uint16;
666
#endif
667
668
#ifndef YYPTRDIFF_T
669
# if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__
670
0
#  define YYPTRDIFF_T __PTRDIFF_TYPE__
671
#  define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__
672
# elif defined PTRDIFF_MAX
673
#  ifndef ptrdiff_t
674
#   include <stddef.h> /* INFRINGES ON USER NAME SPACE */
675
#  endif
676
#  define YYPTRDIFF_T ptrdiff_t
677
#  define YYPTRDIFF_MAXIMUM PTRDIFF_MAX
678
# else
679
#  define YYPTRDIFF_T long
680
#  define YYPTRDIFF_MAXIMUM LONG_MAX
681
# endif
682
#endif
683
684
#ifndef YYSIZE_T
685
# ifdef __SIZE_TYPE__
686
#  define YYSIZE_T __SIZE_TYPE__
687
# elif defined size_t
688
#  define YYSIZE_T size_t
689
# elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
690
#  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
691
#  define YYSIZE_T size_t
692
# else
693
#  define YYSIZE_T unsigned
694
# endif
695
#endif
696
697
#define YYSIZE_MAXIMUM                                  \
698
  YY_CAST (YYPTRDIFF_T,                                 \
699
           (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1)  \
700
            ? YYPTRDIFF_MAXIMUM                         \
701
            : YY_CAST (YYSIZE_T, -1)))
702
703
0
#define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X))
704
705
706
/* Stored state numbers (used for stacks). */
707
typedef yytype_int16 yy_state_t;
708
709
/* State numbers in computations.  */
710
typedef int yy_state_fast_t;
711
712
#ifndef YY_
713
# if defined YYENABLE_NLS && YYENABLE_NLS
714
#  if ENABLE_NLS
715
#   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
716
#   define YY_(Msgid) dgettext ("bison-runtime", Msgid)
717
#  endif
718
# endif
719
# ifndef YY_
720
0
#  define YY_(Msgid) Msgid
721
# endif
722
#endif
723
724
725
#ifndef YY_ATTRIBUTE_PURE
726
# if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__)
727
#  define YY_ATTRIBUTE_PURE __attribute__ ((__pure__))
728
# else
729
#  define YY_ATTRIBUTE_PURE
730
# endif
731
#endif
732
733
#ifndef YY_ATTRIBUTE_UNUSED
734
# if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__)
735
#  define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__))
736
# else
737
#  define YY_ATTRIBUTE_UNUSED
738
# endif
739
#endif
740
741
/* Suppress unused-variable warnings by "using" E.  */
742
#if ! defined lint || defined __GNUC__
743
0
# define YY_USE(E) ((void) (E))
744
#else
745
# define YY_USE(E) /* empty */
746
#endif
747
748
/* Suppress an incorrect diagnostic about yylval being uninitialized.  */
749
#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
750
# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
751
#  define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN                           \
752
    _Pragma ("GCC diagnostic push")                                     \
753
    _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
754
# else
755
#  define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN                           \
756
    _Pragma ("GCC diagnostic push")                                     \
757
    _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")              \
758
    _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
759
# endif
760
# define YY_IGNORE_MAYBE_UNINITIALIZED_END      \
761
    _Pragma ("GCC diagnostic pop")
762
#else
763
0
# define YY_INITIAL_VALUE(Value) Value
764
#endif
765
#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
766
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
767
# define YY_IGNORE_MAYBE_UNINITIALIZED_END
768
#endif
769
#ifndef YY_INITIAL_VALUE
770
# define YY_INITIAL_VALUE(Value) /* Nothing. */
771
#endif
772
773
#if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__
774
# define YY_IGNORE_USELESS_CAST_BEGIN                          \
775
    _Pragma ("GCC diagnostic push")                            \
776
    _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"")
777
# define YY_IGNORE_USELESS_CAST_END            \
778
    _Pragma ("GCC diagnostic pop")
779
#endif
780
#ifndef YY_IGNORE_USELESS_CAST_BEGIN
781
# define YY_IGNORE_USELESS_CAST_BEGIN
782
# define YY_IGNORE_USELESS_CAST_END
783
#endif
784
785
786
0
#define YY_ASSERT(E) ((void) (0 && (E)))
787
788
#if !defined yyoverflow
789
790
/* The parser invokes alloca or malloc; define the necessary symbols.  */
791
792
# ifdef YYSTACK_USE_ALLOCA
793
#  if YYSTACK_USE_ALLOCA
794
#   ifdef __GNUC__
795
#    define YYSTACK_ALLOC __builtin_alloca
796
#   elif defined __BUILTIN_VA_ARG_INCR
797
#    include <alloca.h> /* INFRINGES ON USER NAME SPACE */
798
#   elif defined _AIX
799
#    define YYSTACK_ALLOC __alloca
800
#   elif defined _MSC_VER
801
#    include <malloc.h> /* INFRINGES ON USER NAME SPACE */
802
#    define alloca _alloca
803
#   else
804
#    define YYSTACK_ALLOC alloca
805
#    if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
806
#     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
807
      /* Use EXIT_SUCCESS as a witness for stdlib.h.  */
808
#     ifndef EXIT_SUCCESS
809
#      define EXIT_SUCCESS 0
810
#     endif
811
#    endif
812
#   endif
813
#  endif
814
# endif
815
816
# ifdef YYSTACK_ALLOC
817
   /* Pacify GCC's 'empty if-body' warning.  */
818
#  define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
819
#  ifndef YYSTACK_ALLOC_MAXIMUM
820
    /* The OS might guarantee only one guard page at the bottom of the stack,
821
       and a page size can be as small as 4096 bytes.  So we cannot safely
822
       invoke alloca (N) if N exceeds 4096.  Use a slightly smaller number
823
       to allow for a few compiler-allocated temporary stack slots.  */
824
#   define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
825
#  endif
826
# else
827
#  define YYSTACK_ALLOC YYMALLOC
828
0
#  define YYSTACK_FREE YYFREE
829
#  ifndef YYSTACK_ALLOC_MAXIMUM
830
#   define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
831
#  endif
832
#  if (defined __cplusplus && ! defined EXIT_SUCCESS \
833
       && ! ((defined YYMALLOC || defined malloc) \
834
             && (defined YYFREE || defined free)))
835
#   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
836
#   ifndef EXIT_SUCCESS
837
#    define EXIT_SUCCESS 0
838
#   endif
839
#  endif
840
#  ifndef YYMALLOC
841
#   define YYMALLOC malloc
842
#   if ! defined malloc && ! defined EXIT_SUCCESS
843
void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
844
#   endif
845
#  endif
846
#  ifndef YYFREE
847
0
#   define YYFREE free
848
#   if ! defined free && ! defined EXIT_SUCCESS
849
void free (void *); /* INFRINGES ON USER NAME SPACE */
850
#   endif
851
#  endif
852
# endif
853
#endif /* !defined yyoverflow */
854
855
#if (! defined yyoverflow \
856
     && (! defined __cplusplus \
857
         || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
858
859
/* A type that is properly aligned for any stack member.  */
860
union yyalloc
861
{
862
  yy_state_t yyss_alloc;
863
  YYSTYPE yyvs_alloc;
864
};
865
866
/* The size of the maximum gap between one aligned stack and the next.  */
867
0
# define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1)
868
869
/* The size of an array large to enough to hold all stacks, each with
870
   N elements.  */
871
# define YYSTACK_BYTES(N) \
872
     ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \
873
      + YYSTACK_GAP_MAXIMUM)
874
875
# define YYCOPY_NEEDED 1
876
877
/* Relocate STACK from its old location to the new one.  The
878
   local variables YYSIZE and YYSTACKSIZE give the old and new number of
879
   elements in the stack, and YYPTR gives the new location of the
880
   stack.  Advance YYPTR to a properly aligned location for the next
881
   stack.  */
882
# define YYSTACK_RELOCATE(Stack_alloc, Stack)                           \
883
0
    do                                                                  \
884
0
      {                                                                 \
885
0
        YYPTRDIFF_T yynewbytes;                                         \
886
0
        YYCOPY (&yyptr->Stack_alloc, Stack, yysize);                    \
887
0
        Stack = &yyptr->Stack_alloc;                                    \
888
0
        yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
889
0
        yyptr += yynewbytes / YYSIZEOF (*yyptr);                        \
890
0
      }                                                                 \
891
0
    while (0)
892
893
#endif
894
895
#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
896
/* Copy COUNT objects from SRC to DST.  The source and destination do
897
   not overlap.  */
898
# ifndef YYCOPY
899
#  if defined __GNUC__ && 1 < __GNUC__
900
#   define YYCOPY(Dst, Src, Count) \
901
0
      __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src)))
902
#  else
903
#   define YYCOPY(Dst, Src, Count)              \
904
      do                                        \
905
        {                                       \
906
          YYPTRDIFF_T yyi;                      \
907
          for (yyi = 0; yyi < (Count); yyi++)   \
908
            (Dst)[yyi] = (Src)[yyi];            \
909
        }                                       \
910
      while (0)
911
#  endif
912
# endif
913
#endif /* !YYCOPY_NEEDED */
914
915
/* YYFINAL -- State number of the termination state.  */
916
0
#define YYFINAL  3
917
/* YYLAST -- Last index in YYTABLE.  */
918
0
#define YYLAST   773
919
920
/* YYNTOKENS -- Number of terminals.  */
921
0
#define YYNTOKENS  142
922
/* YYNNTS -- Number of nonterminals.  */
923
#define YYNNTS  47
924
/* YYNRULES -- Number of rules.  */
925
#define YYNRULES  223
926
/* YYNSTATES -- Number of states.  */
927
#define YYNSTATES  298
928
929
/* YYMAXUTOK -- Last valid token kind.  */
930
0
#define YYMAXUTOK   379
931
932
933
/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
934
   as returned by yylex, with out-of-bounds checking.  */
935
#define YYTRANSLATE(YYX)                                \
936
0
  (0 <= (YYX) && (YYX) <= YYMAXUTOK                     \
937
0
   ? YY_CAST (yysymbol_kind_t, yytranslate[YYX])        \
938
0
   : YYSYMBOL_YYUNDEF)
939
940
/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
941
   as returned by yylex.  */
942
static const yytype_uint8 yytranslate[] =
943
{
944
       0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
945
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
946
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
947
       2,     2,     2,   124,     2,     2,     2,   140,   126,     2,
948
     133,   132,   129,   127,     2,   128,     2,   130,     2,     2,
949
       2,     2,     2,     2,     2,     2,     2,     2,   139,     2,
950
     136,   135,   134,     2,     2,     2,     2,     2,     2,     2,
951
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
952
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
953
       2,   137,     2,   138,   141,     2,     2,     2,     2,     2,
954
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
955
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
956
       2,     2,     2,     2,   125,     2,     2,     2,     2,     2,
957
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
958
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
959
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
960
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
961
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
962
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
963
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
964
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
965
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
966
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
967
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
968
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
969
       2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
970
       5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
971
      15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
972
      25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
973
      35,    36,    37,    38,    39,    40,    41,    42,    43,    44,
974
      45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
975
      55,    56,    57,    58,    59,    60,    61,    62,    63,    64,
976
      65,    66,    67,    68,    69,    70,    71,    72,    73,    74,
977
      75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
978
      85,    86,    87,    88,    89,    90,    91,    92,    93,    94,
979
      95,    96,    97,    98,    99,   100,   101,   102,   103,   104,
980
     105,   106,   107,   108,   109,   110,   111,   112,   113,   114,
981
     115,   116,   117,   118,   119,   120,   121,   122,   123,   131
982
};
983
984
#if YYDEBUG
985
/* YYRLINE[YYN] -- Source line where rule number YYN was defined.  */
986
static const yytype_int16 yyrline[] =
987
{
988
       0,   420,   420,   432,   434,   436,   437,   438,   439,   440,
989
     442,   444,   446,   447,   449,   451,   452,   471,   491,   510,
990
     529,   548,   549,   550,   552,   554,   556,   557,   558,   560,
991
     562,   564,   565,   567,   568,   569,   570,   571,   579,   581,
992
     582,   583,   584,   586,   588,   589,   590,   591,   592,   593,
993
     596,   597,   600,   601,   602,   603,   604,   605,   606,   607,
994
     608,   609,   610,   611,   614,   615,   616,   617,   620,   622,
995
     623,   624,   625,   626,   627,   628,   629,   630,   631,   632,
996
     633,   634,   635,   636,   637,   638,   639,   640,   641,   642,
997
     643,   644,   645,   646,   647,   648,   649,   650,   651,   652,
998
     653,   654,   655,   656,   657,   658,   659,   660,   662,   663,
999
     664,   665,   666,   667,   668,   669,   670,   671,   672,   673,
1000
     674,   675,   676,   677,   678,   679,   680,   681,   682,   683,
1001
     686,   687,   688,   689,   690,   691,   694,   699,   702,   706,
1002
     709,   715,   724,   730,   753,   770,   771,   795,   798,   804,
1003
     820,   821,   824,   827,   828,   829,   831,   832,   833,   835,
1004
     836,   838,   839,   840,   841,   842,   843,   844,   845,   846,
1005
     847,   848,   849,   850,   851,   852,   854,   855,   856,   857,
1006
     858,   860,   861,   863,   864,   865,   866,   867,   868,   869,
1007
     871,   872,   873,   874,   877,   878,   880,   881,   882,   883,
1008
     885,   892,   893,   896,   897,   898,   899,   900,   901,   904,
1009
     905,   906,   907,   908,   909,   910,   911,   913,   914,   915,
1010
     916,   918,   931,   932
1011
};
1012
#endif
1013
1014
/** Accessing symbol of state STATE.  */
1015
0
#define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State])
1016
1017
#if YYDEBUG || 0
1018
/* The user-facing name of the symbol whose (internal) number is
1019
   YYSYMBOL.  No bounds checking.  */
1020
static const char *yysymbol_name (yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED;
1021
1022
/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
1023
   First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
1024
static const char *const yytname[] =
1025
{
1026
  "\"end of file\"", "error", "\"invalid token\"", "DST", "SRC", "HOST",
1027
  "GATEWAY", "NET", "NETMASK", "PORT", "PORTRANGE", "LESS", "GREATER",
1028
  "PROTO", "PROTOCHAIN", "CBYTE", "ARP", "RARP", "IP", "SCTP", "TCP",
1029
  "UDP", "ICMP", "IGMP", "IGRP", "PIM", "VRRP", "CARP", "ATALK", "AARP",
1030
  "DECNET", "LAT", "SCA", "MOPRC", "MOPDL", "TK_BROADCAST", "TK_MULTICAST",
1031
  "NUM", "INBOUND", "OUTBOUND", "IFINDEX", "PF_IFNAME", "PF_RSET",
1032
  "PF_RNR", "PF_SRNR", "PF_REASON", "PF_ACTION", "TYPE", "SUBTYPE", "DIR",
1033
  "ADDR1", "ADDR2", "ADDR3", "ADDR4", "RA", "TA", "LINK", "GEQ", "LEQ",
1034
  "NEQ", "ID", "EID", "HID", "HID6", "AID", "LSH", "RSH", "LEN", "IPV6",
1035
  "ICMPV6", "AH", "ESP", "VLAN", "MPLS", "PPPOED", "PPPOES", "GENEVE",
1036
  "VXLAN", "ISO", "ESIS", "CLNP", "ISIS", "L1", "L2", "IIH", "LSP", "SNP",
1037
  "CSNP", "PSNP", "STP", "IPX", "NETBEUI", "LANE", "LLC", "METAC", "BCC",
1038
  "SC", "ILMIC", "OAMF4EC", "OAMF4SC", "OAM", "OAMF4", "CONNECTMSG",
1039
  "METACONNECT", "VPI", "VCI", "RADIO", "FISU", "LSSU", "MSU", "HFISU",
1040
  "HLSSU", "HMSU", "SIO", "OPC", "DPC", "SLS", "HSIO", "HOPC", "HDPC",
1041
  "HSLS", "LEX_ERROR", "OR", "AND", "'!'", "'|'", "'&'", "'+'", "'-'",
1042
  "'*'", "'/'", "UMINUS", "')'", "'('", "'>'", "'='", "'<'", "'['", "']'",
1043
  "':'", "'%'", "'^'", "$accept", "prog", "null", "expr", "and", "or",
1044
  "id", "nid", "not", "paren", "pid", "qid", "term", "head", "rterm",
1045
  "pqual", "dqual", "aqual", "ndaqual", "pname", "other", "pfvar",
1046
  "p80211", "type", "subtype", "type_subtype", "pllc", "dir", "reason",
1047
  "action", "relop", "irelop", "arth", "narth", "byteop", "pnum",
1048
  "atmtype", "atmmultitype", "atmfield", "atmvalue", "atmfieldvalue",
1049
  "atmlistvalue", "mtp2type", "mtp3field", "mtp3value", "mtp3fieldvalue",
1050
  "mtp3listvalue", YY_NULLPTR
1051
};
1052
1053
static const char *
1054
yysymbol_name (yysymbol_kind_t yysymbol)
1055
{
1056
  return yytname[yysymbol];
1057
}
1058
#endif
1059
1060
0
#define YYPACT_NINF (-215)
1061
1062
#define yypact_value_is_default(Yyn) \
1063
0
  ((Yyn) == YYPACT_NINF)
1064
1065
#define YYTABLE_NINF (-42)
1066
1067
#define yytable_value_is_error(Yyn) \
1068
0
  0
1069
1070
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
1071
   STATE-NUM.  */
1072
static const yytype_int16 yypact[] =
1073
{
1074
    -215,    29,   224,  -215,    -5,     0,    11,  -215,  -215,  -215,
1075
    -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,
1076
    -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,    18,
1077
       8,    26,    53,    55,   -24,    37,  -215,  -215,  -215,  -215,
1078
    -215,  -215,   -26,   -26,  -215,   -26,   -26,   -26,  -215,  -215,
1079
    -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,
1080
    -215,  -215,  -215,   -27,  -215,  -215,  -215,  -215,  -215,  -215,
1081
    -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,
1082
    -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,
1083
    -215,  -215,   580,  -215,   -50,   462,   462,  -215,   148,  -215,
1084
     718,    12,  -215,  -215,  -215,   562,  -215,  -215,  -215,  -215,
1085
      21,  -215,    25,  -215,  -215,   -65,  -215,  -215,  -215,  -215,
1086
    -215,  -215,  -215,  -215,  -215,  -215,   -26,  -215,  -215,  -215,
1087
    -215,  -215,  -215,  -215,   580,   -31,   -66,  -215,  -215,   343,
1088
     343,  -215,    41,   -23,   -21,  -215,  -215,     6,   -15,  -215,
1089
    -215,  -215,   148,   148,  -215,   -34,    17,  -215,  -215,  -215,
1090
    -215,  -215,  -215,  -215,  -215,  -215,   -22,    73,   -18,  -215,
1091
    -215,  -215,  -215,  -215,  -215,   162,  -215,  -215,  -215,   580,
1092
    -215,  -215,  -215,   580,   580,   580,   580,   580,   580,   580,
1093
     580,  -215,  -215,  -215,   580,   580,   580,   580,  -215,   104,
1094
     108,   111,  -215,  -215,  -215,   131,   133,   137,  -215,  -215,
1095
    -215,  -215,  -215,  -215,  -215,   139,   -21,   589,  -215,   343,
1096
     343,  -215,    30,  -215,  -215,  -215,  -215,  -215,   115,   141,
1097
     142,  -215,  -215,    50,   -50,   -21,   179,   180,   183,   184,
1098
    -215,  -215,   150,  -215,  -215,  -215,  -215,  -215,  -215,    66,
1099
     -64,   -64,   607,   149,  -106,  -106,   -66,   -66,   589,   589,
1100
     589,   589,  -215,  -101,  -215,  -215,  -215,   -41,  -215,  -215,
1101
    -215,    43,  -215,  -215,  -215,  -215,   148,   148,  -215,  -215,
1102
    -215,  -215,   -10,  -215,   153,  -215,   104,  -215,   131,  -215,
1103
    -215,  -215,  -215,  -215,    59,  -215,  -215,  -215
1104
};
1105
1106
/* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
1107
   Performed when YYTABLE does not specify something else to do.  Zero
1108
   means the default is an error.  */
1109
static const yytype_uint8 yydefact[] =
1110
{
1111
       4,     0,    51,     1,     0,     0,     0,    71,    72,    70,
1112
      73,    74,    75,    76,    77,    78,    79,    80,    81,    82,
1113
      83,    84,    85,    86,    88,    87,   181,   113,   114,     0,
1114
       0,     0,     0,     0,     0,     0,    69,   175,    89,    90,
1115
      91,    92,   117,   119,   120,   122,   124,   126,    93,    94,
1116
     103,    95,    96,    97,    98,    99,   100,   102,   101,   104,
1117
     105,   106,   183,   145,   184,   185,   188,   189,   186,   187,
1118
     190,   191,   192,   193,   194,   195,   107,   203,   204,   205,
1119
     206,   207,   208,   209,   210,   211,   212,   213,   214,   215,
1120
     216,    24,     0,    25,     2,    51,    51,     5,     0,    31,
1121
       0,    50,    44,   127,   129,     0,   160,   159,    45,    46,
1122
       0,    48,     0,   110,   111,     0,   115,   130,   131,   132,
1123
     133,   150,   151,   134,   152,   135,     0,   116,   118,   121,
1124
     123,   125,   147,   146,     0,     0,   173,    11,    10,    51,
1125
      51,    32,     0,   160,   159,    15,    21,    18,    20,    22,
1126
      39,    12,     0,     0,    13,    53,    52,    64,    68,    65,
1127
      66,    67,    36,    37,   108,   109,     0,     0,     0,    58,
1128
      59,    60,    61,    62,    63,    34,    35,    38,   128,     0,
1129
     154,   156,   158,     0,     0,     0,     0,     0,     0,     0,
1130
       0,   153,   155,   157,     0,     0,     0,     0,   200,     0,
1131
       0,     0,    47,   196,   221,     0,     0,     0,    49,   217,
1132
     177,   176,   179,   180,   178,     0,     0,     0,     7,    51,
1133
      51,     6,   159,     9,     8,    40,   174,   182,     0,     0,
1134
       0,    23,    26,    30,     0,    29,     0,     0,     0,     0,
1135
     140,   141,   137,   144,   138,   148,   149,   139,    33,     0,
1136
     171,   172,   169,   168,   163,   164,   165,   166,   167,   170,
1137
      42,    43,   201,     0,   197,   198,   222,     0,   218,   219,
1138
     112,   159,    17,    16,    19,    14,     0,     0,    55,    57,
1139
      54,    56,     0,   161,     0,   199,     0,   220,     0,    27,
1140
      28,   142,   143,   136,     0,   202,   223,   162
1141
};
1142
1143
/* YYPGOTO[NTERM-NUM].  */
1144
static const yytype_int16 yypgoto[] =
1145
{
1146
    -215,  -215,  -215,   197,   -33,  -214,   -88,  -135,     3,    -2,
1147
    -215,  -215,   -93,  -215,  -215,  -215,  -215,    27,  -215,     7,
1148
    -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,  -215,
1149
     -84,   -56,   -67,   -95,  -215,   -39,  -215,  -215,  -215,  -215,
1150
    -182,  -215,  -215,  -215,  -215,  -183,  -215
1151
};
1152
1153
/* YYDEFGOTO[NTERM-NUM].  */
1154
static const yytype_int16 yydefgoto[] =
1155
{
1156
       0,     1,     2,   142,   139,   140,   231,   151,   152,   134,
1157
     233,   234,    97,    98,    99,   100,   175,   176,   177,   135,
1158
     102,   103,   178,   242,   293,   244,   104,   247,   123,   125,
1159
     196,   197,   105,   106,   215,   107,   108,   109,   110,   202,
1160
     203,   263,   111,   112,   208,   209,   267
1161
};
1162
1163
/* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM.  If
1164
   positive, shift that token.  If negative, reduce the rule whose
1165
   number is the opposite.  If YYTABLE_NINF, syntax error.  */
1166
static const yytype_int16 yytable[] =
1167
{
1168
      96,   143,   141,   127,   128,    95,   129,   130,   131,   101,
1169
     150,    26,   -41,   121,   228,   240,   132,   262,   232,   245,
1170
     277,   137,   266,   189,   190,   136,   200,   291,   206,     3,
1171
     -13,   285,   113,   133,   194,   195,   122,   114,   241,   143,
1172
     126,   126,   246,   126,   126,   126,   221,   224,   115,   286,
1173
     292,   218,   223,   288,   201,   116,   207,   144,   198,   154,
1174
     210,   211,   204,   187,   188,   189,   190,   217,   117,   212,
1175
     213,   214,   137,   138,   194,   195,   194,   195,   180,   181,
1176
     182,   137,   180,   181,   182,   232,   118,   216,   236,   237,
1177
     119,   287,   120,    96,    96,   144,   153,   124,    95,    95,
1178
     222,   222,   101,   101,   295,   296,   179,    93,   199,   226,
1179
     205,   227,   249,   154,   235,   230,   250,   251,   252,   253,
1180
     254,   255,   256,   257,   126,   143,   141,   258,   259,   260,
1181
     261,   183,   184,   243,   -41,   -41,   229,   220,   220,   238,
1182
     239,   198,   219,   219,   -41,   264,   101,   101,   265,   179,
1183
     153,   126,   -13,   -13,    93,   191,   192,   193,    93,   191,
1184
     192,   193,   -13,   137,   138,   -29,   -29,   157,   204,   159,
1185
     268,   160,   161,   225,   269,   227,   270,   272,   273,   274,
1186
     222,   271,   275,   278,   279,    26,   280,   281,   289,   290,
1187
     294,   185,   186,   187,   188,   189,   190,   297,   282,    94,
1188
       0,   276,   248,     0,   283,   284,   194,   195,   145,   146,
1189
     147,   148,   149,     0,   183,   184,     0,   220,    96,     0,
1190
       0,     0,   219,   219,    -3,     0,   101,   101,     0,     0,
1191
       0,     0,     0,     0,     0,     4,     5,   154,   154,     6,
1192
       7,     8,     9,    10,    11,    12,    13,    14,    15,    16,
1193
      17,    18,    19,    20,    21,    22,    23,    24,    25,     0,
1194
       0,    26,    27,    28,    29,    30,    31,    32,    33,    34,
1195
      35,     0,    91,     0,   153,   153,   187,   188,   189,   190,
1196
      36,    93,     0,     0,     0,     0,     0,     0,     0,   194,
1197
     195,    37,    38,    39,    40,    41,    42,    43,    44,    45,
1198
      46,    47,    48,    49,    50,    51,    52,    53,    54,    55,
1199
      56,    57,    58,    59,    60,    61,    62,    63,    64,    65,
1200
      66,    67,    68,    69,    70,    71,    72,    73,    74,    75,
1201
      76,    77,    78,    79,    80,    81,    82,    83,    84,    85,
1202
      86,    87,    88,    89,    90,     0,     0,     0,    91,     0,
1203
       0,     0,    92,     0,     4,     5,     0,    93,     6,     7,
1204
       8,     9,    10,    11,    12,    13,    14,    15,    16,    17,
1205
      18,    19,    20,    21,    22,    23,    24,    25,     0,     0,
1206
      26,    27,    28,    29,    30,    31,    32,    33,    34,    35,
1207
       0,     0,     0,     0,     0,     0,     0,     0,     0,    36,
1208
       0,     0,     0,   145,   146,   147,   148,   149,     0,     0,
1209
      37,    38,    39,    40,    41,    42,    43,    44,    45,    46,
1210
      47,    48,    49,    50,    51,    52,    53,    54,    55,    56,
1211
      57,    58,    59,    60,    61,    62,    63,    64,    65,    66,
1212
      67,    68,    69,    70,    71,    72,    73,    74,    75,    76,
1213
      77,    78,    79,    80,    81,    82,    83,    84,    85,    86,
1214
      87,    88,    89,    90,     0,     0,     0,    91,     0,     0,
1215
       0,    92,     0,     4,     5,     0,    93,     6,     7,     8,
1216
       9,    10,    11,    12,    13,    14,    15,    16,    17,    18,
1217
      19,    20,    21,    22,    23,    24,    25,     0,     0,    26,
1218
      27,    28,    29,    30,    31,    32,    33,    34,    35,     0,
1219
       0,     0,     0,     0,     0,     0,     0,     0,    36,     0,
1220
       0,     0,     0,     0,     0,     0,     0,     0,     0,    37,
1221
      38,    39,    40,    41,    42,    43,    44,    45,    46,    47,
1222
      48,    49,    50,    51,    52,    53,    54,    55,    56,    57,
1223
      58,    59,    60,    61,    62,    63,    64,    65,    66,    67,
1224
      68,    69,    70,    71,    72,    73,    74,    75,    76,    77,
1225
      78,    79,    80,    81,    82,    83,    84,    85,    86,    87,
1226
      88,    89,    90,     0,     0,     0,    91,     0,     0,     0,
1227
      92,     0,     0,     0,     0,    93,     7,     8,     9,    10,
1228
      11,    12,    13,    14,    15,    16,    17,    18,    19,    20,
1229
      21,    22,    23,    24,    25,     0,     0,    26,     0,   180,
1230
     181,   182,     0,     0,     0,     0,     0,   183,   184,     0,
1231
       0,     0,     0,     0,     0,     0,    36,     0,     0,     0,
1232
       0,     0,     0,     0,     0,     0,     0,    37,    38,    39,
1233
      40,    41,     0,     0,   183,   184,     0,     0,    48,    49,
1234
      50,    51,    52,    53,    54,    55,    56,    57,    58,    59,
1235
      60,    61,   183,   184,     0,     0,     0,     0,     0,     0,
1236
       0,     0,     0,     0,     0,     0,    76,   185,   186,   187,
1237
     188,   189,   190,     0,     0,     0,   191,   192,   193,     0,
1238
       0,     0,   194,   195,     0,     0,     0,     0,    92,     0,
1239
       0,     0,     0,    93,   185,   186,   187,   188,   189,   190,
1240
       0,   155,   156,   157,   158,   159,     0,   160,   161,   194,
1241
     195,   162,   163,   186,   187,   188,   189,   190,     0,     0,
1242
       0,     0,     0,     0,     0,     0,     0,   194,   195,     0,
1243
       0,     0,     0,   164,   165,     0,     0,     0,     0,     0,
1244
       0,     0,     0,     0,     0,   166,   167,   168,   169,   170,
1245
     171,   172,   173,   174
1246
};
1247
1248
static const yytype_int16 yycheck[] =
1249
{
1250
       2,    96,    95,    42,    43,     2,    45,    46,    47,     2,
1251
      98,    37,     0,    37,     8,    37,    43,   199,   153,    37,
1252
     234,   122,   205,   129,   130,    92,   110,    37,   112,     0,
1253
       0,   132,    37,    60,   140,   141,    60,    37,    60,   134,
1254
      42,    43,    60,    45,    46,    47,   139,   140,    37,   263,
1255
      60,   139,   140,   267,   110,    37,   112,    96,    37,    98,
1256
     125,   126,    37,   127,   128,   129,   130,   134,    60,   134,
1257
     135,   136,   122,   123,   140,   141,   140,   141,    57,    58,
1258
      59,   122,    57,    58,    59,   220,    60,   126,   122,   123,
1259
      37,   132,    37,    95,    96,   134,    98,    60,    95,    96,
1260
     139,   140,    95,    96,   286,   288,   137,   133,   110,   132,
1261
     112,   132,   179,   152,   153,   130,   183,   184,   185,   186,
1262
     187,   188,   189,   190,   126,   220,   219,   194,   195,   196,
1263
     197,    65,    66,    60,   122,   123,   130,   139,   140,   122,
1264
     123,    37,   139,   140,   132,    37,   139,   140,    37,   137,
1265
     152,   153,   122,   123,   133,   134,   135,   136,   133,   134,
1266
     135,   136,   132,   122,   123,   122,   123,     5,    37,     7,
1267
      37,     9,    10,   132,    37,   132,    37,    62,    37,    37,
1268
     219,   220,   132,     4,     4,    37,     3,     3,   276,   277,
1269
      37,   125,   126,   127,   128,   129,   130,   138,    48,     2,
1270
      -1,   234,   175,    -1,   138,   139,   140,   141,    60,    61,
1271
      62,    63,    64,    -1,    65,    66,    -1,   219,   220,    -1,
1272
      -1,    -1,   219,   220,     0,    -1,   219,   220,    -1,    -1,
1273
      -1,    -1,    -1,    -1,    -1,    11,    12,   276,   277,    15,
1274
      16,    17,    18,    19,    20,    21,    22,    23,    24,    25,
1275
      26,    27,    28,    29,    30,    31,    32,    33,    34,    -1,
1276
      -1,    37,    38,    39,    40,    41,    42,    43,    44,    45,
1277
      46,    -1,   124,    -1,   276,   277,   127,   128,   129,   130,
1278
      56,   133,    -1,    -1,    -1,    -1,    -1,    -1,    -1,   140,
1279
     141,    67,    68,    69,    70,    71,    72,    73,    74,    75,
1280
      76,    77,    78,    79,    80,    81,    82,    83,    84,    85,
1281
      86,    87,    88,    89,    90,    91,    92,    93,    94,    95,
1282
      96,    97,    98,    99,   100,   101,   102,   103,   104,   105,
1283
     106,   107,   108,   109,   110,   111,   112,   113,   114,   115,
1284
     116,   117,   118,   119,   120,    -1,    -1,    -1,   124,    -1,
1285
      -1,    -1,   128,    -1,    11,    12,    -1,   133,    15,    16,
1286
      17,    18,    19,    20,    21,    22,    23,    24,    25,    26,
1287
      27,    28,    29,    30,    31,    32,    33,    34,    -1,    -1,
1288
      37,    38,    39,    40,    41,    42,    43,    44,    45,    46,
1289
      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    56,
1290
      -1,    -1,    -1,    60,    61,    62,    63,    64,    -1,    -1,
1291
      67,    68,    69,    70,    71,    72,    73,    74,    75,    76,
1292
      77,    78,    79,    80,    81,    82,    83,    84,    85,    86,
1293
      87,    88,    89,    90,    91,    92,    93,    94,    95,    96,
1294
      97,    98,    99,   100,   101,   102,   103,   104,   105,   106,
1295
     107,   108,   109,   110,   111,   112,   113,   114,   115,   116,
1296
     117,   118,   119,   120,    -1,    -1,    -1,   124,    -1,    -1,
1297
      -1,   128,    -1,    11,    12,    -1,   133,    15,    16,    17,
1298
      18,    19,    20,    21,    22,    23,    24,    25,    26,    27,
1299
      28,    29,    30,    31,    32,    33,    34,    -1,    -1,    37,
1300
      38,    39,    40,    41,    42,    43,    44,    45,    46,    -1,
1301
      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    56,    -1,
1302
      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    67,
1303
      68,    69,    70,    71,    72,    73,    74,    75,    76,    77,
1304
      78,    79,    80,    81,    82,    83,    84,    85,    86,    87,
1305
      88,    89,    90,    91,    92,    93,    94,    95,    96,    97,
1306
      98,    99,   100,   101,   102,   103,   104,   105,   106,   107,
1307
     108,   109,   110,   111,   112,   113,   114,   115,   116,   117,
1308
     118,   119,   120,    -1,    -1,    -1,   124,    -1,    -1,    -1,
1309
     128,    -1,    -1,    -1,    -1,   133,    16,    17,    18,    19,
1310
      20,    21,    22,    23,    24,    25,    26,    27,    28,    29,
1311
      30,    31,    32,    33,    34,    -1,    -1,    37,    -1,    57,
1312
      58,    59,    -1,    -1,    -1,    -1,    -1,    65,    66,    -1,
1313
      -1,    -1,    -1,    -1,    -1,    -1,    56,    -1,    -1,    -1,
1314
      -1,    -1,    -1,    -1,    -1,    -1,    -1,    67,    68,    69,
1315
      70,    71,    -1,    -1,    65,    66,    -1,    -1,    78,    79,
1316
      80,    81,    82,    83,    84,    85,    86,    87,    88,    89,
1317
      90,    91,    65,    66,    -1,    -1,    -1,    -1,    -1,    -1,
1318
      -1,    -1,    -1,    -1,    -1,    -1,   106,   125,   126,   127,
1319
     128,   129,   130,    -1,    -1,    -1,   134,   135,   136,    -1,
1320
      -1,    -1,   140,   141,    -1,    -1,    -1,    -1,   128,    -1,
1321
      -1,    -1,    -1,   133,   125,   126,   127,   128,   129,   130,
1322
      -1,     3,     4,     5,     6,     7,    -1,     9,    10,   140,
1323
     141,    13,    14,   126,   127,   128,   129,   130,    -1,    -1,
1324
      -1,    -1,    -1,    -1,    -1,    -1,    -1,   140,   141,    -1,
1325
      -1,    -1,    -1,    35,    36,    -1,    -1,    -1,    -1,    -1,
1326
      -1,    -1,    -1,    -1,    -1,    47,    48,    49,    50,    51,
1327
      52,    53,    54,    55
1328
};
1329
1330
/* YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
1331
   state STATE-NUM.  */
1332
static const yytype_uint8 yystos[] =
1333
{
1334
       0,   143,   144,     0,    11,    12,    15,    16,    17,    18,
1335
      19,    20,    21,    22,    23,    24,    25,    26,    27,    28,
1336
      29,    30,    31,    32,    33,    34,    37,    38,    39,    40,
1337
      41,    42,    43,    44,    45,    46,    56,    67,    68,    69,
1338
      70,    71,    72,    73,    74,    75,    76,    77,    78,    79,
1339
      80,    81,    82,    83,    84,    85,    86,    87,    88,    89,
1340
      90,    91,    92,    93,    94,    95,    96,    97,    98,    99,
1341
     100,   101,   102,   103,   104,   105,   106,   107,   108,   109,
1342
     110,   111,   112,   113,   114,   115,   116,   117,   118,   119,
1343
     120,   124,   128,   133,   145,   150,   151,   154,   155,   156,
1344
     157,   161,   162,   163,   168,   174,   175,   177,   178,   179,
1345
     180,   184,   185,    37,    37,    37,    37,    60,    60,    37,
1346
      37,    37,    60,   170,    60,   171,   151,   177,   177,   177,
1347
     177,   177,    43,    60,   151,   161,   174,   122,   123,   146,
1348
     147,   154,   145,   175,   177,    60,    61,    62,    63,    64,
1349
     148,   149,   150,   151,   177,     3,     4,     5,     6,     7,
1350
       9,    10,    13,    14,    35,    36,    47,    48,    49,    50,
1351
      51,    52,    53,    54,    55,   158,   159,   160,   164,   137,
1352
      57,    58,    59,    65,    66,   125,   126,   127,   128,   129,
1353
     130,   134,   135,   136,   140,   141,   172,   173,    37,   151,
1354
     172,   173,   181,   182,    37,   151,   172,   173,   186,   187,
1355
     125,   126,   134,   135,   136,   176,   177,   174,   148,   150,
1356
     151,   154,   177,   148,   154,   132,   132,   132,     8,   130,
1357
     130,   148,   149,   152,   153,   177,   122,   123,   122,   123,
1358
      37,    60,   165,    60,   167,    37,    60,   169,   159,   174,
1359
     174,   174,   174,   174,   174,   174,   174,   174,   174,   174,
1360
     174,   174,   182,   183,    37,    37,   187,   188,    37,    37,
1361
      37,   177,    62,    37,    37,   132,   146,   147,     4,     4,
1362
       3,     3,    48,   138,   139,   132,   147,   132,   147,   148,
1363
     148,    37,    60,   166,    37,   182,   187,   138
1364
};
1365
1366
/* YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.  */
1367
static const yytype_uint8 yyr1[] =
1368
{
1369
       0,   142,   143,   143,   144,   145,   145,   145,   145,   145,
1370
     146,   147,   148,   148,   148,   149,   149,   149,   149,   149,
1371
     149,   149,   149,   149,   150,   151,   152,   152,   152,   153,
1372
     153,   154,   154,   155,   155,   155,   155,   155,   155,   156,
1373
     156,   156,   156,   156,   156,   156,   156,   156,   156,   156,
1374
     157,   157,   158,   158,   158,   158,   158,   158,   158,   158,
1375
     158,   158,   158,   158,   159,   159,   159,   159,   160,   161,
1376
     161,   161,   161,   161,   161,   161,   161,   161,   161,   161,
1377
     161,   161,   161,   161,   161,   161,   161,   161,   161,   161,
1378
     161,   161,   161,   161,   161,   161,   161,   161,   161,   161,
1379
     161,   161,   161,   161,   161,   161,   161,   161,   162,   162,
1380
     162,   162,   162,   162,   162,   162,   162,   162,   162,   162,
1381
     162,   162,   162,   162,   162,   162,   162,   162,   162,   162,
1382
     163,   163,   163,   163,   163,   163,   164,   164,   164,   164,
1383
     165,   165,   166,   166,   167,   168,   168,   168,   169,   169,
1384
     170,   170,   171,   172,   172,   172,   173,   173,   173,   174,
1385
     174,   175,   175,   175,   175,   175,   175,   175,   175,   175,
1386
     175,   175,   175,   175,   175,   175,   176,   176,   176,   176,
1387
     176,   177,   177,   178,   178,   178,   178,   178,   178,   178,
1388
     179,   179,   179,   179,   180,   180,   181,   181,   181,   181,
1389
     182,   183,   183,   184,   184,   184,   184,   184,   184,   185,
1390
     185,   185,   185,   185,   185,   185,   185,   186,   186,   186,
1391
     186,   187,   188,   188
1392
};
1393
1394
/* YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.  */
1395
static const yytype_int8 yyr2[] =
1396
{
1397
       0,     2,     2,     1,     0,     1,     3,     3,     3,     3,
1398
       1,     1,     1,     1,     3,     1,     3,     3,     1,     3,
1399
       1,     1,     1,     2,     1,     1,     1,     3,     3,     1,
1400
       1,     1,     2,     3,     2,     2,     2,     2,     2,     2,
1401
       3,     1,     3,     3,     1,     1,     1,     2,     1,     2,
1402
       1,     0,     1,     1,     3,     3,     3,     3,     1,     1,
1403
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
1404
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
1405
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
1406
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
1407
       1,     1,     1,     1,     1,     1,     1,     1,     2,     2,
1408
       2,     2,     4,     1,     1,     2,     2,     1,     2,     1,
1409
       1,     2,     1,     2,     1,     2,     1,     1,     2,     1,
1410
       2,     2,     2,     2,     2,     2,     4,     2,     2,     2,
1411
       1,     1,     1,     1,     1,     1,     2,     2,     1,     1,
1412
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
1413
       1,     4,     6,     3,     3,     3,     3,     3,     3,     3,
1414
       3,     3,     3,     2,     3,     1,     1,     1,     1,     1,
1415
       1,     1,     3,     1,     1,     1,     1,     1,     1,     1,
1416
       1,     1,     1,     1,     1,     1,     1,     2,     2,     3,
1417
       1,     1,     3,     1,     1,     1,     1,     1,     1,     1,
1418
       1,     1,     1,     1,     1,     1,     1,     1,     2,     2,
1419
       3,     1,     1,     3
1420
};
1421
1422
1423
enum { YYENOMEM = -2 };
1424
1425
#define yyerrok         (yyerrstatus = 0)
1426
#define yyclearin       (yychar = YYEMPTY)
1427
1428
0
#define YYACCEPT        goto yyacceptlab
1429
0
#define YYABORT         goto yyabortlab
1430
0
#define YYERROR         goto yyerrorlab
1431
0
#define YYNOMEM         goto yyexhaustedlab
1432
1433
1434
#define YYRECOVERING()  (!!yyerrstatus)
1435
1436
#define YYBACKUP(Token, Value)                                    \
1437
  do                                                              \
1438
    if (yychar == YYEMPTY)                                        \
1439
      {                                                           \
1440
        yychar = (Token);                                         \
1441
        yylval = (Value);                                         \
1442
        YYPOPSTACK (yylen);                                       \
1443
        yystate = *yyssp;                                         \
1444
        goto yybackup;                                            \
1445
      }                                                           \
1446
    else                                                          \
1447
      {                                                           \
1448
        yyerror (yyscanner, cstate, YY_("syntax error: cannot back up")); \
1449
        YYERROR;                                                  \
1450
      }                                                           \
1451
  while (0)
1452
1453
/* Backward compatibility with an undocumented macro.
1454
   Use YYerror or YYUNDEF. */
1455
#define YYERRCODE YYUNDEF
1456
1457
1458
/* Enable debugging if requested.  */
1459
#if YYDEBUG
1460
1461
# ifndef YYFPRINTF
1462
#  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
1463
#  define YYFPRINTF fprintf
1464
# endif
1465
1466
# define YYDPRINTF(Args)                        \
1467
do {                                            \
1468
  if (yydebug)                                  \
1469
    YYFPRINTF Args;                             \
1470
} while (0)
1471
1472
1473
1474
1475
# define YY_SYMBOL_PRINT(Title, Kind, Value, Location)                    \
1476
do {                                                                      \
1477
  if (yydebug)                                                            \
1478
    {                                                                     \
1479
      YYFPRINTF (stderr, "%s ", Title);                                   \
1480
      yy_symbol_print (stderr,                                            \
1481
                  Kind, Value, yyscanner, cstate); \
1482
      YYFPRINTF (stderr, "\n");                                           \
1483
    }                                                                     \
1484
} while (0)
1485
1486
1487
/*-----------------------------------.
1488
| Print this symbol's value on YYO.  |
1489
`-----------------------------------*/
1490
1491
static void
1492
yy_symbol_value_print (FILE *yyo,
1493
                       yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep, void *yyscanner, compiler_state_t *cstate)
1494
{
1495
  FILE *yyoutput = yyo;
1496
  YY_USE (yyoutput);
1497
  YY_USE (yyscanner);
1498
  YY_USE (cstate);
1499
  if (!yyvaluep)
1500
    return;
1501
  YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
1502
  YY_USE (yykind);
1503
  YY_IGNORE_MAYBE_UNINITIALIZED_END
1504
}
1505
1506
1507
/*---------------------------.
1508
| Print this symbol on YYO.  |
1509
`---------------------------*/
1510
1511
static void
1512
yy_symbol_print (FILE *yyo,
1513
                 yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep, void *yyscanner, compiler_state_t *cstate)
1514
{
1515
  YYFPRINTF (yyo, "%s %s (",
1516
             yykind < YYNTOKENS ? "token" : "nterm", yysymbol_name (yykind));
1517
1518
  yy_symbol_value_print (yyo, yykind, yyvaluep, yyscanner, cstate);
1519
  YYFPRINTF (yyo, ")");
1520
}
1521
1522
/*------------------------------------------------------------------.
1523
| yy_stack_print -- Print the state stack from its BOTTOM up to its |
1524
| TOP (included).                                                   |
1525
`------------------------------------------------------------------*/
1526
1527
static void
1528
yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop)
1529
{
1530
  YYFPRINTF (stderr, "Stack now");
1531
  for (; yybottom <= yytop; yybottom++)
1532
    {
1533
      int yybot = *yybottom;
1534
      YYFPRINTF (stderr, " %d", yybot);
1535
    }
1536
  YYFPRINTF (stderr, "\n");
1537
}
1538
1539
# define YY_STACK_PRINT(Bottom, Top)                            \
1540
do {                                                            \
1541
  if (yydebug)                                                  \
1542
    yy_stack_print ((Bottom), (Top));                           \
1543
} while (0)
1544
1545
1546
/*------------------------------------------------.
1547
| Report that the YYRULE is going to be reduced.  |
1548
`------------------------------------------------*/
1549
1550
static void
1551
yy_reduce_print (yy_state_t *yyssp, YYSTYPE *yyvsp,
1552
                 int yyrule, void *yyscanner, compiler_state_t *cstate)
1553
{
1554
  int yylno = yyrline[yyrule];
1555
  int yynrhs = yyr2[yyrule];
1556
  int yyi;
1557
  YYFPRINTF (stderr, "Reducing stack by rule %d (line %d):\n",
1558
             yyrule - 1, yylno);
1559
  /* The symbols being reduced.  */
1560
  for (yyi = 0; yyi < yynrhs; yyi++)
1561
    {
1562
      YYFPRINTF (stderr, "   $%d = ", yyi + 1);
1563
      yy_symbol_print (stderr,
1564
                       YY_ACCESSING_SYMBOL (+yyssp[yyi + 1 - yynrhs]),
1565
                       &yyvsp[(yyi + 1) - (yynrhs)], yyscanner, cstate);
1566
      YYFPRINTF (stderr, "\n");
1567
    }
1568
}
1569
1570
# define YY_REDUCE_PRINT(Rule)          \
1571
do {                                    \
1572
  if (yydebug)                          \
1573
    yy_reduce_print (yyssp, yyvsp, Rule, yyscanner, cstate); \
1574
} while (0)
1575
1576
/* Nonzero means print parse trace.  It is left uninitialized so that
1577
   multiple parsers can coexist.  */
1578
int yydebug;
1579
#else /* !YYDEBUG */
1580
0
# define YYDPRINTF(Args) ((void) 0)
1581
# define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
1582
# define YY_STACK_PRINT(Bottom, Top)
1583
# define YY_REDUCE_PRINT(Rule)
1584
#endif /* !YYDEBUG */
1585
1586
1587
/* YYINITDEPTH -- initial size of the parser's stacks.  */
1588
#ifndef YYINITDEPTH
1589
0
# define YYINITDEPTH 200
1590
#endif
1591
1592
/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
1593
   if the built-in stack extension method is used).
1594
1595
   Do not make this value too large; the results are undefined if
1596
   YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
1597
   evaluated with infinite-precision integer arithmetic.  */
1598
1599
#ifndef YYMAXDEPTH
1600
0
# define YYMAXDEPTH 10000
1601
#endif
1602
1603
1604
1605
1606
1607
1608
/*-----------------------------------------------.
1609
| Release the memory associated to this symbol.  |
1610
`-----------------------------------------------*/
1611
1612
static void
1613
yydestruct (const char *yymsg,
1614
            yysymbol_kind_t yykind, YYSTYPE *yyvaluep, void *yyscanner, compiler_state_t *cstate)
1615
0
{
1616
0
  YY_USE (yyvaluep);
1617
0
  YY_USE (yyscanner);
1618
0
  YY_USE (cstate);
1619
0
  if (!yymsg)
1620
0
    yymsg = "Deleting";
1621
0
  YY_SYMBOL_PRINT (yymsg, yykind, yyvaluep, yylocationp);
1622
1623
0
  YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
1624
0
  YY_USE (yykind);
1625
0
  YY_IGNORE_MAYBE_UNINITIALIZED_END
1626
0
}
1627
1628
1629
1630
1631
1632
1633
/*----------.
1634
| yyparse.  |
1635
`----------*/
1636
1637
int
1638
yyparse (void *yyscanner, compiler_state_t *cstate)
1639
0
{
1640
/* Lookahead token kind.  */
1641
0
int yychar;
1642
1643
1644
/* The semantic value of the lookahead symbol.  */
1645
/* Default value used for initialization, for pacifying older GCCs
1646
   or non-GCC compilers.  */
1647
0
YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
1648
0
YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
1649
1650
    /* Number of syntax errors so far.  */
1651
0
    int yynerrs = 0;
1652
1653
0
    yy_state_fast_t yystate = 0;
1654
    /* Number of tokens to shift before error messages enabled.  */
1655
0
    int yyerrstatus = 0;
1656
1657
    /* Refer to the stacks through separate pointers, to allow yyoverflow
1658
       to reallocate them elsewhere.  */
1659
1660
    /* Their size.  */
1661
0
    YYPTRDIFF_T yystacksize = YYINITDEPTH;
1662
1663
    /* The state stack: array, bottom, top.  */
1664
0
    yy_state_t yyssa[YYINITDEPTH];
1665
0
    yy_state_t *yyss = yyssa;
1666
0
    yy_state_t *yyssp = yyss;
1667
1668
    /* The semantic value stack: array, bottom, top.  */
1669
0
    YYSTYPE yyvsa[YYINITDEPTH];
1670
0
    YYSTYPE *yyvs = yyvsa;
1671
0
    YYSTYPE *yyvsp = yyvs;
1672
1673
0
  int yyn;
1674
  /* The return value of yyparse.  */
1675
0
  int yyresult;
1676
  /* Lookahead symbol kind.  */
1677
0
  yysymbol_kind_t yytoken = YYSYMBOL_YYEMPTY;
1678
  /* The variables used to return semantic value and location from the
1679
     action routines.  */
1680
0
  YYSTYPE yyval;
1681
1682
1683
1684
0
#define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
1685
1686
  /* The number of symbols on the RHS of the reduced rule.
1687
     Keep to zero when no symbol should be popped.  */
1688
0
  int yylen = 0;
1689
1690
0
  YYDPRINTF ((stderr, "Starting parse\n"));
1691
1692
0
  yychar = YYEMPTY; /* Cause a token to be read.  */
1693
1694
0
  goto yysetstate;
1695
1696
1697
/*------------------------------------------------------------.
1698
| yynewstate -- push a new state, which is found in yystate.  |
1699
`------------------------------------------------------------*/
1700
0
yynewstate:
1701
  /* In all cases, when you get here, the value and location stacks
1702
     have just been pushed.  So pushing a state here evens the stacks.  */
1703
0
  yyssp++;
1704
1705
1706
/*--------------------------------------------------------------------.
1707
| yysetstate -- set current state (the top of the stack) to yystate.  |
1708
`--------------------------------------------------------------------*/
1709
0
yysetstate:
1710
0
  YYDPRINTF ((stderr, "Entering state %d\n", yystate));
1711
0
  YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
1712
0
  YY_IGNORE_USELESS_CAST_BEGIN
1713
0
  *yyssp = YY_CAST (yy_state_t, yystate);
1714
0
  YY_IGNORE_USELESS_CAST_END
1715
0
  YY_STACK_PRINT (yyss, yyssp);
1716
1717
0
  if (yyss + yystacksize - 1 <= yyssp)
1718
#if !defined yyoverflow && !defined YYSTACK_RELOCATE
1719
    YYNOMEM;
1720
#else
1721
0
    {
1722
      /* Get the current used size of the three stacks, in elements.  */
1723
0
      YYPTRDIFF_T yysize = yyssp - yyss + 1;
1724
1725
# if defined yyoverflow
1726
      {
1727
        /* Give user a chance to reallocate the stack.  Use copies of
1728
           these so that the &'s don't force the real ones into
1729
           memory.  */
1730
        yy_state_t *yyss1 = yyss;
1731
        YYSTYPE *yyvs1 = yyvs;
1732
1733
        /* Each stack pointer address is followed by the size of the
1734
           data in use in that stack, in bytes.  This used to be a
1735
           conditional around just the two extra args, but that might
1736
           be undefined if yyoverflow is a macro.  */
1737
        yyoverflow (YY_("memory exhausted"),
1738
                    &yyss1, yysize * YYSIZEOF (*yyssp),
1739
                    &yyvs1, yysize * YYSIZEOF (*yyvsp),
1740
                    &yystacksize);
1741
        yyss = yyss1;
1742
        yyvs = yyvs1;
1743
      }
1744
# else /* defined YYSTACK_RELOCATE */
1745
      /* Extend the stack our own way.  */
1746
0
      if (YYMAXDEPTH <= yystacksize)
1747
0
        YYNOMEM;
1748
0
      yystacksize *= 2;
1749
0
      if (YYMAXDEPTH < yystacksize)
1750
0
        yystacksize = YYMAXDEPTH;
1751
1752
0
      {
1753
0
        yy_state_t *yyss1 = yyss;
1754
0
        union yyalloc *yyptr =
1755
0
          YY_CAST (union yyalloc *,
1756
0
                   YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize))));
1757
0
        if (! yyptr)
1758
0
          YYNOMEM;
1759
0
        YYSTACK_RELOCATE (yyss_alloc, yyss);
1760
0
        YYSTACK_RELOCATE (yyvs_alloc, yyvs);
1761
0
#  undef YYSTACK_RELOCATE
1762
0
        if (yyss1 != yyssa)
1763
0
          YYSTACK_FREE (yyss1);
1764
0
      }
1765
0
# endif
1766
1767
0
      yyssp = yyss + yysize - 1;
1768
0
      yyvsp = yyvs + yysize - 1;
1769
1770
0
      YY_IGNORE_USELESS_CAST_BEGIN
1771
0
      YYDPRINTF ((stderr, "Stack size increased to %ld\n",
1772
0
                  YY_CAST (long, yystacksize)));
1773
0
      YY_IGNORE_USELESS_CAST_END
1774
1775
0
      if (yyss + yystacksize - 1 <= yyssp)
1776
0
        YYABORT;
1777
0
    }
1778
0
#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
1779
1780
1781
0
  if (yystate == YYFINAL)
1782
0
    YYACCEPT;
1783
1784
0
  goto yybackup;
1785
1786
1787
/*-----------.
1788
| yybackup.  |
1789
`-----------*/
1790
0
yybackup:
1791
  /* Do appropriate processing given the current state.  Read a
1792
     lookahead token if we need one and don't already have one.  */
1793
1794
  /* First try to decide what to do without reference to lookahead token.  */
1795
0
  yyn = yypact[yystate];
1796
0
  if (yypact_value_is_default (yyn))
1797
0
    goto yydefault;
1798
1799
  /* Not known => get a lookahead token if don't already have one.  */
1800
1801
  /* YYCHAR is either empty, or end-of-input, or a valid lookahead.  */
1802
0
  if (yychar == YYEMPTY)
1803
0
    {
1804
0
      YYDPRINTF ((stderr, "Reading a token\n"));
1805
0
      yychar = yylex (&yylval, yyscanner);
1806
0
    }
1807
1808
0
  if (yychar <= YYEOF)
1809
0
    {
1810
0
      yychar = YYEOF;
1811
0
      yytoken = YYSYMBOL_YYEOF;
1812
0
      YYDPRINTF ((stderr, "Now at end of input.\n"));
1813
0
    }
1814
0
  else if (yychar == YYerror)
1815
0
    {
1816
      /* The scanner already issued an error message, process directly
1817
         to error recovery.  But do not keep the error token as
1818
         lookahead, it is too special and may lead us to an endless
1819
         loop in error recovery. */
1820
0
      yychar = YYUNDEF;
1821
0
      yytoken = YYSYMBOL_YYerror;
1822
0
      goto yyerrlab1;
1823
0
    }
1824
0
  else
1825
0
    {
1826
0
      yytoken = YYTRANSLATE (yychar);
1827
0
      YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
1828
0
    }
1829
1830
  /* If the proper action on seeing token YYTOKEN is to reduce or to
1831
     detect an error, take that action.  */
1832
0
  yyn += yytoken;
1833
0
  if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
1834
0
    goto yydefault;
1835
0
  yyn = yytable[yyn];
1836
0
  if (yyn <= 0)
1837
0
    {
1838
0
      if (yytable_value_is_error (yyn))
1839
0
        goto yyerrlab;
1840
0
      yyn = -yyn;
1841
0
      goto yyreduce;
1842
0
    }
1843
1844
  /* Count tokens shifted since error; after three, turn off error
1845
     status.  */
1846
0
  if (yyerrstatus)
1847
0
    yyerrstatus--;
1848
1849
  /* Shift the lookahead token.  */
1850
0
  YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
1851
0
  yystate = yyn;
1852
0
  YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
1853
0
  *++yyvsp = yylval;
1854
0
  YY_IGNORE_MAYBE_UNINITIALIZED_END
1855
1856
  /* Discard the shifted token.  */
1857
0
  yychar = YYEMPTY;
1858
0
  goto yynewstate;
1859
1860
1861
/*-----------------------------------------------------------.
1862
| yydefault -- do the default action for the current state.  |
1863
`-----------------------------------------------------------*/
1864
0
yydefault:
1865
0
  yyn = yydefact[yystate];
1866
0
  if (yyn == 0)
1867
0
    goto yyerrlab;
1868
0
  goto yyreduce;
1869
1870
1871
/*-----------------------------.
1872
| yyreduce -- do a reduction.  |
1873
`-----------------------------*/
1874
0
yyreduce:
1875
  /* yyn is the number of a rule to reduce with.  */
1876
0
  yylen = yyr2[yyn];
1877
1878
  /* If YYLEN is nonzero, implement the default value of the action:
1879
     '$$ = $1'.
1880
1881
     Otherwise, the following line sets YYVAL to garbage.
1882
     This behavior is undocumented and Bison
1883
     users should not rely upon it.  Assigning to YYVAL
1884
     unconditionally makes the parser a bit smaller, and it avoids a
1885
     GCC warning that YYVAL may be used uninitialized.  */
1886
0
  yyval = yyvsp[1-yylen];
1887
1888
1889
0
  YY_REDUCE_PRINT (yyn);
1890
0
  switch (yyn)
1891
0
    {
1892
0
  case 2: /* prog: null expr  */
1893
0
#line 421 "/src/libpcap/build/grammar.y"
1894
0
{
1895
  /*
1896
   * I'm not sure we have a reason to use yynerrs, but it's
1897
   * declared, and incremented, whether we need it or not,
1898
   * which means that Clang 15 will give a "set but not
1899
   * used" warning.  This should suppress the warning for
1900
   * yynerrs without suppressing it for other variables.
1901
   */
1902
0
  (void) yynerrs;
1903
0
  CHECK_INT_VAL(finish_parse(cstate, (yyvsp[0].blk).b));
1904
0
}
1905
0
#line 1906 "/src/libpcap/build/grammar.c"
1906
0
    break;
1907
1908
0
  case 4: /* null: %empty  */
1909
0
#line 434 "/src/libpcap/build/grammar.y"
1910
0
                                { (yyval.blk).q = qerr; }
1911
0
#line 1912 "/src/libpcap/build/grammar.c"
1912
0
    break;
1913
1914
0
  case 6: /* expr: expr and term  */
1915
0
#line 437 "/src/libpcap/build/grammar.y"
1916
0
                                { (yyvsp[0].blk).b = gen_and((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
1917
0
#line 1918 "/src/libpcap/build/grammar.c"
1918
0
    break;
1919
1920
0
  case 7: /* expr: expr and id  */
1921
0
#line 438 "/src/libpcap/build/grammar.y"
1922
0
                                { (yyvsp[0].blk).b = gen_and((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
1923
0
#line 1924 "/src/libpcap/build/grammar.c"
1924
0
    break;
1925
1926
0
  case 8: /* expr: expr or term  */
1927
0
#line 439 "/src/libpcap/build/grammar.y"
1928
0
                                { (yyvsp[0].blk).b = gen_or((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
1929
0
#line 1930 "/src/libpcap/build/grammar.c"
1930
0
    break;
1931
1932
0
  case 9: /* expr: expr or id  */
1933
0
#line 440 "/src/libpcap/build/grammar.y"
1934
0
                                { (yyvsp[0].blk).b = gen_or((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
1935
0
#line 1936 "/src/libpcap/build/grammar.c"
1936
0
    break;
1937
1938
0
  case 10: /* and: AND  */
1939
0
#line 442 "/src/libpcap/build/grammar.y"
1940
0
                                { (yyval.blk) = (yyvsp[-1].blk); }
1941
0
#line 1942 "/src/libpcap/build/grammar.c"
1942
0
    break;
1943
1944
0
  case 11: /* or: OR  */
1945
0
#line 444 "/src/libpcap/build/grammar.y"
1946
0
                                { (yyval.blk) = (yyvsp[-1].blk); }
1947
0
#line 1948 "/src/libpcap/build/grammar.c"
1948
0
    break;
1949
1950
0
  case 13: /* id: pnum  */
1951
0
#line 447 "/src/libpcap/build/grammar.y"
1952
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_ncode(cstate, NULL, (yyvsp[0].h),
1953
0
               (yyval.blk).q = (yyvsp[-1].blk).q))); }
1954
0
#line 1955 "/src/libpcap/build/grammar.c"
1955
0
    break;
1956
1957
0
  case 14: /* id: paren pid ')'  */
1958
0
#line 449 "/src/libpcap/build/grammar.y"
1959
0
                                { (yyval.blk) = (yyvsp[-1].blk); }
1960
0
#line 1961 "/src/libpcap/build/grammar.c"
1961
0
    break;
1962
1963
0
  case 15: /* nid: ID  */
1964
0
#line 451 "/src/libpcap/build/grammar.y"
1965
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_PTR_VAL(((yyval.blk).b = gen_scode(cstate, (yyvsp[0].s), (yyval.blk).q = (yyvsp[-1].blk).q))); }
1966
0
#line 1967 "/src/libpcap/build/grammar.c"
1967
0
    break;
1968
1969
0
  case 16: /* nid: HID '/' NUM  */
1970
0
#line 452 "/src/libpcap/build/grammar.y"
1971
0
                                {
1972
0
          CHECK_PTR_VAL((yyvsp[-2].s));
1973
          /* Check whether HID/NUM is being used when appropriate */
1974
0
          (yyval.blk).q = (yyvsp[-3].blk).q;
1975
0
          if ((yyval.blk).q.addr == Q_PORT) {
1976
0
          bpf_set_error(cstate, "'port' qualifier applied to IPv4 address and prefix length");
1977
0
          YYABORT;
1978
0
          } else if ((yyval.blk).q.addr == Q_PORTRANGE) {
1979
0
          bpf_set_error(cstate, "'portrange' qualifier applied to IPv4 address and prefix length");
1980
0
          YYABORT;
1981
0
          } else if ((yyval.blk).q.addr == Q_PROTO) {
1982
0
          bpf_set_error(cstate, "'proto' qualifier applied to IPv4 address and prefix length");
1983
0
          YYABORT;
1984
0
          } else if ((yyval.blk).q.addr == Q_PROTOCHAIN) {
1985
0
          bpf_set_error(cstate, "'protochain' qualifier applied to IPv4 address and prefix length");
1986
0
          YYABORT;
1987
0
          }
1988
0
          CHECK_PTR_VAL(((yyval.blk).b = gen_mcode(cstate, (yyvsp[-2].s), NULL, (yyvsp[0].h), (yyval.blk).q)));
1989
0
        }
1990
0
#line 1991 "/src/libpcap/build/grammar.c"
1991
0
    break;
1992
1993
0
  case 17: /* nid: HID NETMASK HID  */
1994
0
#line 471 "/src/libpcap/build/grammar.y"
1995
0
                                {
1996
0
          CHECK_PTR_VAL((yyvsp[-2].s));
1997
0
          CHECK_PTR_VAL((yyvsp[0].s));
1998
          /* Check whether HID mask HID is being used when appropriate */
1999
0
          (yyval.blk).q = (yyvsp[-3].blk).q;
2000
0
          if ((yyval.blk).q.addr == Q_PORT) {
2001
0
          bpf_set_error(cstate, "'port' qualifier applied to IPv4 address and netmask");
2002
0
          YYABORT;
2003
0
          } else if ((yyval.blk).q.addr == Q_PORTRANGE) {
2004
0
          bpf_set_error(cstate, "'portrange' qualifier applied to IPv4 address and netmask");
2005
0
          YYABORT;
2006
0
          } else if ((yyval.blk).q.addr == Q_PROTO) {
2007
0
          bpf_set_error(cstate, "'proto' qualifier applied to IPv4 address and netmask");
2008
0
          YYABORT;
2009
0
          } else if ((yyval.blk).q.addr == Q_PROTOCHAIN) {
2010
0
          bpf_set_error(cstate, "'protochain' qualifier applied to IPv4 address and netmask");
2011
0
          YYABORT;
2012
0
          }
2013
0
          CHECK_PTR_VAL(((yyval.blk).b = gen_mcode(cstate, (yyvsp[-2].s), (yyvsp[0].s), 0, (yyval.blk).q)));
2014
0
        }
2015
0
#line 2016 "/src/libpcap/build/grammar.c"
2016
0
    break;
2017
2018
0
  case 18: /* nid: HID  */
2019
0
#line 491 "/src/libpcap/build/grammar.y"
2020
0
                                {
2021
0
          CHECK_PTR_VAL((yyvsp[0].s));
2022
          /* Check whether HID is being used when appropriate */
2023
0
          (yyval.blk).q = (yyvsp[-1].blk).q;
2024
0
          if ((yyval.blk).q.addr == Q_PORT) {
2025
0
          bpf_set_error(cstate, "'port' qualifier applied to IPv4 address");
2026
0
          YYABORT;
2027
0
          } else if ((yyval.blk).q.addr == Q_PORTRANGE) {
2028
0
          bpf_set_error(cstate, "'portrange' qualifier applied to IPv4 address");
2029
0
          YYABORT;
2030
0
          } else if ((yyval.blk).q.addr == Q_PROTO) {
2031
0
          bpf_set_error(cstate, "'proto' qualifier applied to IPv4 address");
2032
0
          YYABORT;
2033
0
          } else if ((yyval.blk).q.addr == Q_PROTOCHAIN) {
2034
0
          bpf_set_error(cstate, "'protochain' qualifier applied to IPv4 address");
2035
0
          YYABORT;
2036
0
          }
2037
0
          CHECK_PTR_VAL(((yyval.blk).b = gen_ncode(cstate, (yyvsp[0].s), 0, (yyval.blk).q)));
2038
0
        }
2039
0
#line 2040 "/src/libpcap/build/grammar.c"
2040
0
    break;
2041
2042
0
  case 19: /* nid: HID6 '/' NUM  */
2043
0
#line 510 "/src/libpcap/build/grammar.y"
2044
0
                                {
2045
0
          CHECK_PTR_VAL((yyvsp[-2].s));
2046
          /* Check whether HID6/NUM is being used when appropriate */
2047
0
          (yyval.blk).q = (yyvsp[-3].blk).q;
2048
0
          if ((yyval.blk).q.addr == Q_PORT) {
2049
0
          bpf_set_error(cstate, "'port' qualifier applied to IPv6 address and prefix length");
2050
0
          YYABORT;
2051
0
          } else if ((yyval.blk).q.addr == Q_PORTRANGE) {
2052
0
          bpf_set_error(cstate, "'portrange' qualifier applied to IPv6 address and prefix length");
2053
0
          YYABORT;
2054
0
          } else if ((yyval.blk).q.addr == Q_PROTO) {
2055
0
          bpf_set_error(cstate, "'proto' qualifier applied to IPv6 address and prefix length ");
2056
0
          YYABORT;
2057
0
          } else if ((yyval.blk).q.addr == Q_PROTOCHAIN) {
2058
0
          bpf_set_error(cstate, "'protochain' qualifier applied to IPv6 address and prefix length");
2059
0
          YYABORT;
2060
0
          }
2061
0
          CHECK_PTR_VAL(((yyval.blk).b = gen_mcode6(cstate, (yyvsp[-2].s), (yyvsp[0].h), (yyval.blk).q)));
2062
0
        }
2063
0
#line 2064 "/src/libpcap/build/grammar.c"
2064
0
    break;
2065
2066
0
  case 20: /* nid: HID6  */
2067
0
#line 529 "/src/libpcap/build/grammar.y"
2068
0
                                {
2069
0
          CHECK_PTR_VAL((yyvsp[0].s));
2070
          /* Check whether HID6 is being used when appropriate */
2071
0
          (yyval.blk).q = (yyvsp[-1].blk).q;
2072
0
          if ((yyval.blk).q.addr == Q_PORT) {
2073
0
          bpf_set_error(cstate, "'port' qualifier applied to IPv6 address");
2074
0
          YYABORT;
2075
0
          } else if ((yyval.blk).q.addr == Q_PORTRANGE) {
2076
0
          bpf_set_error(cstate, "'portrange' qualifier applied to IPv6 address");
2077
0
          YYABORT;
2078
0
          } else if ((yyval.blk).q.addr == Q_PROTO) {
2079
0
          bpf_set_error(cstate, "'proto' qualifier applied to IPv6 address");
2080
0
          YYABORT;
2081
0
          } else if ((yyval.blk).q.addr == Q_PROTOCHAIN) {
2082
0
          bpf_set_error(cstate, "'protochain' qualifier applied to IPv6 address");
2083
0
          YYABORT;
2084
0
          }
2085
0
          CHECK_PTR_VAL(((yyval.blk).b = gen_mcode6(cstate, (yyvsp[0].s), 128, (yyval.blk).q)));
2086
0
        }
2087
0
#line 2088 "/src/libpcap/build/grammar.c"
2088
0
    break;
2089
2090
0
  case 21: /* nid: EID  */
2091
0
#line 548 "/src/libpcap/build/grammar.y"
2092
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_PTR_VAL(((yyval.blk).b = gen_ecode(cstate, (yyvsp[0].s), (yyval.blk).q = (yyvsp[-1].blk).q))); }
2093
0
#line 2094 "/src/libpcap/build/grammar.c"
2094
0
    break;
2095
2096
0
  case 22: /* nid: AID  */
2097
0
#line 549 "/src/libpcap/build/grammar.y"
2098
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_PTR_VAL(((yyval.blk).b = gen_acode(cstate, (yyvsp[0].s), (yyval.blk).q = (yyvsp[-1].blk).q))); }
2099
0
#line 2100 "/src/libpcap/build/grammar.c"
2100
0
    break;
2101
2102
0
  case 23: /* nid: not id  */
2103
0
#line 550 "/src/libpcap/build/grammar.y"
2104
0
                                { gen_not((yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
2105
0
#line 2106 "/src/libpcap/build/grammar.c"
2106
0
    break;
2107
2108
0
  case 24: /* not: '!'  */
2109
0
#line 552 "/src/libpcap/build/grammar.y"
2110
0
                                { (yyval.blk) = (yyvsp[-1].blk); }
2111
0
#line 2112 "/src/libpcap/build/grammar.c"
2112
0
    break;
2113
2114
0
  case 25: /* paren: '('  */
2115
0
#line 554 "/src/libpcap/build/grammar.y"
2116
0
                                { (yyval.blk) = (yyvsp[-1].blk); }
2117
0
#line 2118 "/src/libpcap/build/grammar.c"
2118
0
    break;
2119
2120
0
  case 27: /* pid: qid and id  */
2121
0
#line 557 "/src/libpcap/build/grammar.y"
2122
0
                                { (yyvsp[0].blk).b = gen_and((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
2123
0
#line 2124 "/src/libpcap/build/grammar.c"
2124
0
    break;
2125
2126
0
  case 28: /* pid: qid or id  */
2127
0
#line 558 "/src/libpcap/build/grammar.y"
2128
0
                                { (yyvsp[0].blk).b = gen_or((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
2129
0
#line 2130 "/src/libpcap/build/grammar.c"
2130
0
    break;
2131
2132
0
  case 29: /* qid: pnum  */
2133
0
#line 560 "/src/libpcap/build/grammar.y"
2134
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_ncode(cstate, NULL, (yyvsp[0].h),
2135
0
               (yyval.blk).q = (yyvsp[-1].blk).q))); }
2136
0
#line 2137 "/src/libpcap/build/grammar.c"
2137
0
    break;
2138
2139
0
  case 32: /* term: not term  */
2140
0
#line 565 "/src/libpcap/build/grammar.y"
2141
0
                                { gen_not((yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
2142
0
#line 2143 "/src/libpcap/build/grammar.c"
2143
0
    break;
2144
2145
0
  case 33: /* head: pqual dqual aqual  */
2146
0
#line 567 "/src/libpcap/build/grammar.y"
2147
0
                                { QSET((yyval.blk).q, (yyvsp[-2].i), (yyvsp[-1].i), (yyvsp[0].i)); }
2148
0
#line 2149 "/src/libpcap/build/grammar.c"
2149
0
    break;
2150
2151
0
  case 34: /* head: pqual dqual  */
2152
0
#line 568 "/src/libpcap/build/grammar.y"
2153
0
                                { QSET((yyval.blk).q, (yyvsp[-1].i), (yyvsp[0].i), Q_DEFAULT); }
2154
0
#line 2155 "/src/libpcap/build/grammar.c"
2155
0
    break;
2156
2157
0
  case 35: /* head: pqual aqual  */
2158
0
#line 569 "/src/libpcap/build/grammar.y"
2159
0
                                { QSET((yyval.blk).q, (yyvsp[-1].i), Q_DEFAULT, (yyvsp[0].i)); }
2160
0
#line 2161 "/src/libpcap/build/grammar.c"
2161
0
    break;
2162
2163
0
  case 36: /* head: pqual PROTO  */
2164
0
#line 570 "/src/libpcap/build/grammar.y"
2165
0
                                { QSET((yyval.blk).q, (yyvsp[-1].i), Q_DEFAULT, Q_PROTO); }
2166
0
#line 2167 "/src/libpcap/build/grammar.c"
2167
0
    break;
2168
2169
0
  case 37: /* head: pqual PROTOCHAIN  */
2170
0
#line 571 "/src/libpcap/build/grammar.y"
2171
0
                                {
2172
#ifdef NO_PROTOCHAIN
2173
          bpf_set_error(cstate, "protochain not supported");
2174
          YYABORT;
2175
#else
2176
0
          QSET((yyval.blk).q, (yyvsp[-1].i), Q_DEFAULT, Q_PROTOCHAIN);
2177
0
#endif
2178
0
        }
2179
0
#line 2180 "/src/libpcap/build/grammar.c"
2180
0
    break;
2181
2182
0
  case 38: /* head: pqual ndaqual  */
2183
0
#line 579 "/src/libpcap/build/grammar.y"
2184
0
                                { QSET((yyval.blk).q, (yyvsp[-1].i), Q_DEFAULT, (yyvsp[0].i)); }
2185
0
#line 2186 "/src/libpcap/build/grammar.c"
2186
0
    break;
2187
2188
0
  case 39: /* rterm: head id  */
2189
0
#line 581 "/src/libpcap/build/grammar.y"
2190
0
                                { (yyval.blk) = (yyvsp[0].blk); }
2191
0
#line 2192 "/src/libpcap/build/grammar.c"
2192
0
    break;
2193
2194
0
  case 40: /* rterm: paren expr ')'  */
2195
0
#line 582 "/src/libpcap/build/grammar.y"
2196
0
                                { (yyval.blk).b = (yyvsp[-1].blk).b; (yyval.blk).q = (yyvsp[-2].blk).q; }
2197
0
#line 2198 "/src/libpcap/build/grammar.c"
2198
0
    break;
2199
2200
0
  case 41: /* rterm: pname  */
2201
0
#line 583 "/src/libpcap/build/grammar.y"
2202
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_proto_abbrev(cstate, (yyvsp[0].i)))); (yyval.blk).q = qerr; }
2203
0
#line 2204 "/src/libpcap/build/grammar.c"
2204
0
    break;
2205
2206
0
  case 42: /* rterm: arth relop arth  */
2207
0
#line 584 "/src/libpcap/build/grammar.y"
2208
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_relation(cstate, (yyvsp[-1].i), (yyvsp[-2].a), (yyvsp[0].a), 0)));
2209
0
          (yyval.blk).q = qerr; }
2210
0
#line 2211 "/src/libpcap/build/grammar.c"
2211
0
    break;
2212
2213
0
  case 43: /* rterm: arth irelop arth  */
2214
0
#line 586 "/src/libpcap/build/grammar.y"
2215
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_relation(cstate, (yyvsp[-1].i), (yyvsp[-2].a), (yyvsp[0].a), 1)));
2216
0
          (yyval.blk).q = qerr; }
2217
0
#line 2218 "/src/libpcap/build/grammar.c"
2218
0
    break;
2219
2220
0
  case 44: /* rterm: other  */
2221
0
#line 588 "/src/libpcap/build/grammar.y"
2222
0
                                { (yyval.blk).b = (yyvsp[0].rblk); (yyval.blk).q = qerr; }
2223
0
#line 2224 "/src/libpcap/build/grammar.c"
2224
0
    break;
2225
2226
0
  case 45: /* rterm: atmtype  */
2227
0
#line 589 "/src/libpcap/build/grammar.y"
2228
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_atmtype_abbrev(cstate, (yyvsp[0].i)))); (yyval.blk).q = qerr; }
2229
0
#line 2230 "/src/libpcap/build/grammar.c"
2230
0
    break;
2231
2232
0
  case 46: /* rterm: atmmultitype  */
2233
0
#line 590 "/src/libpcap/build/grammar.y"
2234
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_atmmulti_abbrev(cstate, (yyvsp[0].i)))); (yyval.blk).q = qerr; }
2235
0
#line 2236 "/src/libpcap/build/grammar.c"
2236
0
    break;
2237
2238
0
  case 47: /* rterm: atmfield atmvalue  */
2239
0
#line 591 "/src/libpcap/build/grammar.y"
2240
0
                                { (yyval.blk).b = (yyvsp[0].blk).b; (yyval.blk).q = qerr; }
2241
0
#line 2242 "/src/libpcap/build/grammar.c"
2242
0
    break;
2243
2244
0
  case 48: /* rterm: mtp2type  */
2245
0
#line 592 "/src/libpcap/build/grammar.y"
2246
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_mtp2type_abbrev(cstate, (yyvsp[0].i)))); (yyval.blk).q = qerr; }
2247
0
#line 2248 "/src/libpcap/build/grammar.c"
2248
0
    break;
2249
2250
0
  case 49: /* rterm: mtp3field mtp3value  */
2251
0
#line 593 "/src/libpcap/build/grammar.y"
2252
0
                                { (yyval.blk).b = (yyvsp[0].blk).b; (yyval.blk).q = qerr; }
2253
0
#line 2254 "/src/libpcap/build/grammar.c"
2254
0
    break;
2255
2256
0
  case 51: /* pqual: %empty  */
2257
0
#line 597 "/src/libpcap/build/grammar.y"
2258
0
                                { (yyval.i) = Q_DEFAULT; }
2259
0
#line 2260 "/src/libpcap/build/grammar.c"
2260
0
    break;
2261
2262
0
  case 52: /* dqual: SRC  */
2263
0
#line 600 "/src/libpcap/build/grammar.y"
2264
0
                                { (yyval.i) = Q_SRC; }
2265
0
#line 2266 "/src/libpcap/build/grammar.c"
2266
0
    break;
2267
2268
0
  case 53: /* dqual: DST  */
2269
0
#line 601 "/src/libpcap/build/grammar.y"
2270
0
                                { (yyval.i) = Q_DST; }
2271
0
#line 2272 "/src/libpcap/build/grammar.c"
2272
0
    break;
2273
2274
0
  case 54: /* dqual: SRC OR DST  */
2275
0
#line 602 "/src/libpcap/build/grammar.y"
2276
0
                                { (yyval.i) = Q_OR; }
2277
0
#line 2278 "/src/libpcap/build/grammar.c"
2278
0
    break;
2279
2280
0
  case 55: /* dqual: DST OR SRC  */
2281
0
#line 603 "/src/libpcap/build/grammar.y"
2282
0
                                { (yyval.i) = Q_OR; }
2283
0
#line 2284 "/src/libpcap/build/grammar.c"
2284
0
    break;
2285
2286
0
  case 56: /* dqual: SRC AND DST  */
2287
0
#line 604 "/src/libpcap/build/grammar.y"
2288
0
                                { (yyval.i) = Q_AND; }
2289
0
#line 2290 "/src/libpcap/build/grammar.c"
2290
0
    break;
2291
2292
0
  case 57: /* dqual: DST AND SRC  */
2293
0
#line 605 "/src/libpcap/build/grammar.y"
2294
0
                                { (yyval.i) = Q_AND; }
2295
0
#line 2296 "/src/libpcap/build/grammar.c"
2296
0
    break;
2297
2298
0
  case 58: /* dqual: ADDR1  */
2299
0
#line 606 "/src/libpcap/build/grammar.y"
2300
0
                                { (yyval.i) = Q_ADDR1; }
2301
0
#line 2302 "/src/libpcap/build/grammar.c"
2302
0
    break;
2303
2304
0
  case 59: /* dqual: ADDR2  */
2305
0
#line 607 "/src/libpcap/build/grammar.y"
2306
0
                                { (yyval.i) = Q_ADDR2; }
2307
0
#line 2308 "/src/libpcap/build/grammar.c"
2308
0
    break;
2309
2310
0
  case 60: /* dqual: ADDR3  */
2311
0
#line 608 "/src/libpcap/build/grammar.y"
2312
0
                                { (yyval.i) = Q_ADDR3; }
2313
0
#line 2314 "/src/libpcap/build/grammar.c"
2314
0
    break;
2315
2316
0
  case 61: /* dqual: ADDR4  */
2317
0
#line 609 "/src/libpcap/build/grammar.y"
2318
0
                                { (yyval.i) = Q_ADDR4; }
2319
0
#line 2320 "/src/libpcap/build/grammar.c"
2320
0
    break;
2321
2322
0
  case 62: /* dqual: RA  */
2323
0
#line 610 "/src/libpcap/build/grammar.y"
2324
0
                                { (yyval.i) = Q_RA; }
2325
0
#line 2326 "/src/libpcap/build/grammar.c"
2326
0
    break;
2327
2328
0
  case 63: /* dqual: TA  */
2329
0
#line 611 "/src/libpcap/build/grammar.y"
2330
0
                                { (yyval.i) = Q_TA; }
2331
0
#line 2332 "/src/libpcap/build/grammar.c"
2332
0
    break;
2333
2334
0
  case 64: /* aqual: HOST  */
2335
0
#line 614 "/src/libpcap/build/grammar.y"
2336
0
                                { (yyval.i) = Q_HOST; }
2337
0
#line 2338 "/src/libpcap/build/grammar.c"
2338
0
    break;
2339
2340
0
  case 65: /* aqual: NET  */
2341
0
#line 615 "/src/libpcap/build/grammar.y"
2342
0
                                { (yyval.i) = Q_NET; }
2343
0
#line 2344 "/src/libpcap/build/grammar.c"
2344
0
    break;
2345
2346
0
  case 66: /* aqual: PORT  */
2347
0
#line 616 "/src/libpcap/build/grammar.y"
2348
0
                                { (yyval.i) = Q_PORT; }
2349
0
#line 2350 "/src/libpcap/build/grammar.c"
2350
0
    break;
2351
2352
0
  case 67: /* aqual: PORTRANGE  */
2353
0
#line 617 "/src/libpcap/build/grammar.y"
2354
0
                                { (yyval.i) = Q_PORTRANGE; }
2355
0
#line 2356 "/src/libpcap/build/grammar.c"
2356
0
    break;
2357
2358
0
  case 68: /* ndaqual: GATEWAY  */
2359
0
#line 620 "/src/libpcap/build/grammar.y"
2360
0
                                { (yyval.i) = Q_GATEWAY; }
2361
0
#line 2362 "/src/libpcap/build/grammar.c"
2362
0
    break;
2363
2364
0
  case 69: /* pname: LINK  */
2365
0
#line 622 "/src/libpcap/build/grammar.y"
2366
0
                                { (yyval.i) = Q_LINK; }
2367
0
#line 2368 "/src/libpcap/build/grammar.c"
2368
0
    break;
2369
2370
0
  case 70: /* pname: IP  */
2371
0
#line 623 "/src/libpcap/build/grammar.y"
2372
0
                                { (yyval.i) = Q_IP; }
2373
0
#line 2374 "/src/libpcap/build/grammar.c"
2374
0
    break;
2375
2376
0
  case 71: /* pname: ARP  */
2377
0
#line 624 "/src/libpcap/build/grammar.y"
2378
0
                                { (yyval.i) = Q_ARP; }
2379
0
#line 2380 "/src/libpcap/build/grammar.c"
2380
0
    break;
2381
2382
0
  case 72: /* pname: RARP  */
2383
0
#line 625 "/src/libpcap/build/grammar.y"
2384
0
                                { (yyval.i) = Q_RARP; }
2385
0
#line 2386 "/src/libpcap/build/grammar.c"
2386
0
    break;
2387
2388
0
  case 73: /* pname: SCTP  */
2389
0
#line 626 "/src/libpcap/build/grammar.y"
2390
0
                                { (yyval.i) = Q_SCTP; }
2391
0
#line 2392 "/src/libpcap/build/grammar.c"
2392
0
    break;
2393
2394
0
  case 74: /* pname: TCP  */
2395
0
#line 627 "/src/libpcap/build/grammar.y"
2396
0
                                { (yyval.i) = Q_TCP; }
2397
0
#line 2398 "/src/libpcap/build/grammar.c"
2398
0
    break;
2399
2400
0
  case 75: /* pname: UDP  */
2401
0
#line 628 "/src/libpcap/build/grammar.y"
2402
0
                                { (yyval.i) = Q_UDP; }
2403
0
#line 2404 "/src/libpcap/build/grammar.c"
2404
0
    break;
2405
2406
0
  case 76: /* pname: ICMP  */
2407
0
#line 629 "/src/libpcap/build/grammar.y"
2408
0
                                { (yyval.i) = Q_ICMP; }
2409
0
#line 2410 "/src/libpcap/build/grammar.c"
2410
0
    break;
2411
2412
0
  case 77: /* pname: IGMP  */
2413
0
#line 630 "/src/libpcap/build/grammar.y"
2414
0
                                { (yyval.i) = Q_IGMP; }
2415
0
#line 2416 "/src/libpcap/build/grammar.c"
2416
0
    break;
2417
2418
0
  case 78: /* pname: IGRP  */
2419
0
#line 631 "/src/libpcap/build/grammar.y"
2420
0
                                { (yyval.i) = Q_IGRP; }
2421
0
#line 2422 "/src/libpcap/build/grammar.c"
2422
0
    break;
2423
2424
0
  case 79: /* pname: PIM  */
2425
0
#line 632 "/src/libpcap/build/grammar.y"
2426
0
                                { (yyval.i) = Q_PIM; }
2427
0
#line 2428 "/src/libpcap/build/grammar.c"
2428
0
    break;
2429
2430
0
  case 80: /* pname: VRRP  */
2431
0
#line 633 "/src/libpcap/build/grammar.y"
2432
0
                                { (yyval.i) = Q_VRRP; }
2433
0
#line 2434 "/src/libpcap/build/grammar.c"
2434
0
    break;
2435
2436
0
  case 81: /* pname: CARP  */
2437
0
#line 634 "/src/libpcap/build/grammar.y"
2438
0
                                { (yyval.i) = Q_CARP; }
2439
0
#line 2440 "/src/libpcap/build/grammar.c"
2440
0
    break;
2441
2442
0
  case 82: /* pname: ATALK  */
2443
0
#line 635 "/src/libpcap/build/grammar.y"
2444
0
                                { (yyval.i) = Q_ATALK; }
2445
0
#line 2446 "/src/libpcap/build/grammar.c"
2446
0
    break;
2447
2448
0
  case 83: /* pname: AARP  */
2449
0
#line 636 "/src/libpcap/build/grammar.y"
2450
0
                                { (yyval.i) = Q_AARP; }
2451
0
#line 2452 "/src/libpcap/build/grammar.c"
2452
0
    break;
2453
2454
0
  case 84: /* pname: DECNET  */
2455
0
#line 637 "/src/libpcap/build/grammar.y"
2456
0
                                { (yyval.i) = Q_DECNET; }
2457
0
#line 2458 "/src/libpcap/build/grammar.c"
2458
0
    break;
2459
2460
0
  case 85: /* pname: LAT  */
2461
0
#line 638 "/src/libpcap/build/grammar.y"
2462
0
                                { (yyval.i) = Q_LAT; }
2463
0
#line 2464 "/src/libpcap/build/grammar.c"
2464
0
    break;
2465
2466
0
  case 86: /* pname: SCA  */
2467
0
#line 639 "/src/libpcap/build/grammar.y"
2468
0
                                { (yyval.i) = Q_SCA; }
2469
0
#line 2470 "/src/libpcap/build/grammar.c"
2470
0
    break;
2471
2472
0
  case 87: /* pname: MOPDL  */
2473
0
#line 640 "/src/libpcap/build/grammar.y"
2474
0
                                { (yyval.i) = Q_MOPDL; }
2475
0
#line 2476 "/src/libpcap/build/grammar.c"
2476
0
    break;
2477
2478
0
  case 88: /* pname: MOPRC  */
2479
0
#line 641 "/src/libpcap/build/grammar.y"
2480
0
                                { (yyval.i) = Q_MOPRC; }
2481
0
#line 2482 "/src/libpcap/build/grammar.c"
2482
0
    break;
2483
2484
0
  case 89: /* pname: IPV6  */
2485
0
#line 642 "/src/libpcap/build/grammar.y"
2486
0
                                { (yyval.i) = Q_IPV6; }
2487
0
#line 2488 "/src/libpcap/build/grammar.c"
2488
0
    break;
2489
2490
0
  case 90: /* pname: ICMPV6  */
2491
0
#line 643 "/src/libpcap/build/grammar.y"
2492
0
                                { (yyval.i) = Q_ICMPV6; }
2493
0
#line 2494 "/src/libpcap/build/grammar.c"
2494
0
    break;
2495
2496
0
  case 91: /* pname: AH  */
2497
0
#line 644 "/src/libpcap/build/grammar.y"
2498
0
                                { (yyval.i) = Q_AH; }
2499
0
#line 2500 "/src/libpcap/build/grammar.c"
2500
0
    break;
2501
2502
0
  case 92: /* pname: ESP  */
2503
0
#line 645 "/src/libpcap/build/grammar.y"
2504
0
                                { (yyval.i) = Q_ESP; }
2505
0
#line 2506 "/src/libpcap/build/grammar.c"
2506
0
    break;
2507
2508
0
  case 93: /* pname: ISO  */
2509
0
#line 646 "/src/libpcap/build/grammar.y"
2510
0
                                { (yyval.i) = Q_ISO; }
2511
0
#line 2512 "/src/libpcap/build/grammar.c"
2512
0
    break;
2513
2514
0
  case 94: /* pname: ESIS  */
2515
0
#line 647 "/src/libpcap/build/grammar.y"
2516
0
                                { (yyval.i) = Q_ESIS; }
2517
0
#line 2518 "/src/libpcap/build/grammar.c"
2518
0
    break;
2519
2520
0
  case 95: /* pname: ISIS  */
2521
0
#line 648 "/src/libpcap/build/grammar.y"
2522
0
                                { (yyval.i) = Q_ISIS; }
2523
0
#line 2524 "/src/libpcap/build/grammar.c"
2524
0
    break;
2525
2526
0
  case 96: /* pname: L1  */
2527
0
#line 649 "/src/libpcap/build/grammar.y"
2528
0
                                { (yyval.i) = Q_ISIS_L1; }
2529
0
#line 2530 "/src/libpcap/build/grammar.c"
2530
0
    break;
2531
2532
0
  case 97: /* pname: L2  */
2533
0
#line 650 "/src/libpcap/build/grammar.y"
2534
0
                                { (yyval.i) = Q_ISIS_L2; }
2535
0
#line 2536 "/src/libpcap/build/grammar.c"
2536
0
    break;
2537
2538
0
  case 98: /* pname: IIH  */
2539
0
#line 651 "/src/libpcap/build/grammar.y"
2540
0
                                { (yyval.i) = Q_ISIS_IIH; }
2541
0
#line 2542 "/src/libpcap/build/grammar.c"
2542
0
    break;
2543
2544
0
  case 99: /* pname: LSP  */
2545
0
#line 652 "/src/libpcap/build/grammar.y"
2546
0
                                { (yyval.i) = Q_ISIS_LSP; }
2547
0
#line 2548 "/src/libpcap/build/grammar.c"
2548
0
    break;
2549
2550
0
  case 100: /* pname: SNP  */
2551
0
#line 653 "/src/libpcap/build/grammar.y"
2552
0
                                { (yyval.i) = Q_ISIS_SNP; }
2553
0
#line 2554 "/src/libpcap/build/grammar.c"
2554
0
    break;
2555
2556
0
  case 101: /* pname: PSNP  */
2557
0
#line 654 "/src/libpcap/build/grammar.y"
2558
0
                                { (yyval.i) = Q_ISIS_PSNP; }
2559
0
#line 2560 "/src/libpcap/build/grammar.c"
2560
0
    break;
2561
2562
0
  case 102: /* pname: CSNP  */
2563
0
#line 655 "/src/libpcap/build/grammar.y"
2564
0
                                { (yyval.i) = Q_ISIS_CSNP; }
2565
0
#line 2566 "/src/libpcap/build/grammar.c"
2566
0
    break;
2567
2568
0
  case 103: /* pname: CLNP  */
2569
0
#line 656 "/src/libpcap/build/grammar.y"
2570
0
                                { (yyval.i) = Q_CLNP; }
2571
0
#line 2572 "/src/libpcap/build/grammar.c"
2572
0
    break;
2573
2574
0
  case 104: /* pname: STP  */
2575
0
#line 657 "/src/libpcap/build/grammar.y"
2576
0
                                { (yyval.i) = Q_STP; }
2577
0
#line 2578 "/src/libpcap/build/grammar.c"
2578
0
    break;
2579
2580
0
  case 105: /* pname: IPX  */
2581
0
#line 658 "/src/libpcap/build/grammar.y"
2582
0
                                { (yyval.i) = Q_IPX; }
2583
0
#line 2584 "/src/libpcap/build/grammar.c"
2584
0
    break;
2585
2586
0
  case 106: /* pname: NETBEUI  */
2587
0
#line 659 "/src/libpcap/build/grammar.y"
2588
0
                                { (yyval.i) = Q_NETBEUI; }
2589
0
#line 2590 "/src/libpcap/build/grammar.c"
2590
0
    break;
2591
2592
0
  case 107: /* pname: RADIO  */
2593
0
#line 660 "/src/libpcap/build/grammar.y"
2594
0
                                { (yyval.i) = Q_RADIO; }
2595
0
#line 2596 "/src/libpcap/build/grammar.c"
2596
0
    break;
2597
2598
0
  case 108: /* other: pqual TK_BROADCAST  */
2599
0
#line 662 "/src/libpcap/build/grammar.y"
2600
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_broadcast(cstate, (yyvsp[-1].i)))); }
2601
0
#line 2602 "/src/libpcap/build/grammar.c"
2602
0
    break;
2603
2604
0
  case 109: /* other: pqual TK_MULTICAST  */
2605
0
#line 663 "/src/libpcap/build/grammar.y"
2606
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_multicast(cstate, (yyvsp[-1].i)))); }
2607
0
#line 2608 "/src/libpcap/build/grammar.c"
2608
0
    break;
2609
2610
0
  case 110: /* other: LESS NUM  */
2611
0
#line 664 "/src/libpcap/build/grammar.y"
2612
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_less(cstate, (yyvsp[0].h)))); }
2613
0
#line 2614 "/src/libpcap/build/grammar.c"
2614
0
    break;
2615
2616
0
  case 111: /* other: GREATER NUM  */
2617
0
#line 665 "/src/libpcap/build/grammar.y"
2618
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_greater(cstate, (yyvsp[0].h)))); }
2619
0
#line 2620 "/src/libpcap/build/grammar.c"
2620
0
    break;
2621
2622
0
  case 112: /* other: CBYTE NUM byteop NUM  */
2623
0
#line 666 "/src/libpcap/build/grammar.y"
2624
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_byteop(cstate, (yyvsp[-1].i), (yyvsp[-2].h), (yyvsp[0].h)))); }
2625
0
#line 2626 "/src/libpcap/build/grammar.c"
2626
0
    break;
2627
2628
0
  case 113: /* other: INBOUND  */
2629
0
#line 667 "/src/libpcap/build/grammar.y"
2630
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_inbound_outbound(cstate, 0))); }
2631
0
#line 2632 "/src/libpcap/build/grammar.c"
2632
0
    break;
2633
2634
0
  case 114: /* other: OUTBOUND  */
2635
0
#line 668 "/src/libpcap/build/grammar.y"
2636
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_inbound_outbound(cstate, 1))); }
2637
0
#line 2638 "/src/libpcap/build/grammar.c"
2638
0
    break;
2639
2640
0
  case 115: /* other: IFINDEX NUM  */
2641
0
#line 669 "/src/libpcap/build/grammar.y"
2642
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_ifindex(cstate, (yyvsp[0].h)))); }
2643
0
#line 2644 "/src/libpcap/build/grammar.c"
2644
0
    break;
2645
2646
0
  case 116: /* other: VLAN pnum  */
2647
0
#line 670 "/src/libpcap/build/grammar.y"
2648
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_vlan(cstate, (yyvsp[0].h), 1))); }
2649
0
#line 2650 "/src/libpcap/build/grammar.c"
2650
0
    break;
2651
2652
0
  case 117: /* other: VLAN  */
2653
0
#line 671 "/src/libpcap/build/grammar.y"
2654
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_vlan(cstate, 0, 0))); }
2655
0
#line 2656 "/src/libpcap/build/grammar.c"
2656
0
    break;
2657
2658
0
  case 118: /* other: MPLS pnum  */
2659
0
#line 672 "/src/libpcap/build/grammar.y"
2660
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_mpls(cstate, (yyvsp[0].h), 1))); }
2661
0
#line 2662 "/src/libpcap/build/grammar.c"
2662
0
    break;
2663
2664
0
  case 119: /* other: MPLS  */
2665
0
#line 673 "/src/libpcap/build/grammar.y"
2666
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_mpls(cstate, 0, 0))); }
2667
0
#line 2668 "/src/libpcap/build/grammar.c"
2668
0
    break;
2669
2670
0
  case 120: /* other: PPPOED  */
2671
0
#line 674 "/src/libpcap/build/grammar.y"
2672
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pppoed(cstate))); }
2673
0
#line 2674 "/src/libpcap/build/grammar.c"
2674
0
    break;
2675
2676
0
  case 121: /* other: PPPOES pnum  */
2677
0
#line 675 "/src/libpcap/build/grammar.y"
2678
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pppoes(cstate, (yyvsp[0].h), 1))); }
2679
0
#line 2680 "/src/libpcap/build/grammar.c"
2680
0
    break;
2681
2682
0
  case 122: /* other: PPPOES  */
2683
0
#line 676 "/src/libpcap/build/grammar.y"
2684
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pppoes(cstate, 0, 0))); }
2685
0
#line 2686 "/src/libpcap/build/grammar.c"
2686
0
    break;
2687
2688
0
  case 123: /* other: GENEVE pnum  */
2689
0
#line 677 "/src/libpcap/build/grammar.y"
2690
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_geneve(cstate, (yyvsp[0].h), 1))); }
2691
0
#line 2692 "/src/libpcap/build/grammar.c"
2692
0
    break;
2693
2694
0
  case 124: /* other: GENEVE  */
2695
0
#line 678 "/src/libpcap/build/grammar.y"
2696
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_geneve(cstate, 0, 0))); }
2697
0
#line 2698 "/src/libpcap/build/grammar.c"
2698
0
    break;
2699
2700
0
  case 125: /* other: VXLAN pnum  */
2701
0
#line 679 "/src/libpcap/build/grammar.y"
2702
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_vxlan(cstate, (yyvsp[0].h), 1))); }
2703
0
#line 2704 "/src/libpcap/build/grammar.c"
2704
0
    break;
2705
2706
0
  case 126: /* other: VXLAN  */
2707
0
#line 680 "/src/libpcap/build/grammar.y"
2708
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_vxlan(cstate, 0, 0))); }
2709
0
#line 2710 "/src/libpcap/build/grammar.c"
2710
0
    break;
2711
2712
0
  case 127: /* other: pfvar  */
2713
0
#line 681 "/src/libpcap/build/grammar.y"
2714
0
                                { (yyval.rblk) = (yyvsp[0].rblk); }
2715
0
#line 2716 "/src/libpcap/build/grammar.c"
2716
0
    break;
2717
2718
0
  case 128: /* other: pqual p80211  */
2719
0
#line 682 "/src/libpcap/build/grammar.y"
2720
0
                                { (yyval.rblk) = (yyvsp[0].rblk); }
2721
0
#line 2722 "/src/libpcap/build/grammar.c"
2722
0
    break;
2723
2724
0
  case 129: /* other: pllc  */
2725
0
#line 683 "/src/libpcap/build/grammar.y"
2726
0
                                { (yyval.rblk) = (yyvsp[0].rblk); }
2727
0
#line 2728 "/src/libpcap/build/grammar.c"
2728
0
    break;
2729
2730
0
  case 130: /* pfvar: PF_IFNAME ID  */
2731
0
#line 686 "/src/libpcap/build/grammar.y"
2732
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_PTR_VAL(((yyval.rblk) = gen_pf_ifname(cstate, (yyvsp[0].s)))); }
2733
0
#line 2734 "/src/libpcap/build/grammar.c"
2734
0
    break;
2735
2736
0
  case 131: /* pfvar: PF_RSET ID  */
2737
0
#line 687 "/src/libpcap/build/grammar.y"
2738
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_PTR_VAL(((yyval.rblk) = gen_pf_ruleset(cstate, (yyvsp[0].s)))); }
2739
0
#line 2740 "/src/libpcap/build/grammar.c"
2740
0
    break;
2741
2742
0
  case 132: /* pfvar: PF_RNR NUM  */
2743
0
#line 688 "/src/libpcap/build/grammar.y"
2744
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pf_rnr(cstate, (yyvsp[0].h)))); }
2745
0
#line 2746 "/src/libpcap/build/grammar.c"
2746
0
    break;
2747
2748
0
  case 133: /* pfvar: PF_SRNR NUM  */
2749
0
#line 689 "/src/libpcap/build/grammar.y"
2750
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pf_srnr(cstate, (yyvsp[0].h)))); }
2751
0
#line 2752 "/src/libpcap/build/grammar.c"
2752
0
    break;
2753
2754
0
  case 134: /* pfvar: PF_REASON reason  */
2755
0
#line 690 "/src/libpcap/build/grammar.y"
2756
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pf_reason(cstate, (yyvsp[0].i)))); }
2757
0
#line 2758 "/src/libpcap/build/grammar.c"
2758
0
    break;
2759
2760
0
  case 135: /* pfvar: PF_ACTION action  */
2761
0
#line 691 "/src/libpcap/build/grammar.y"
2762
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_pf_action(cstate, (yyvsp[0].i)))); }
2763
0
#line 2764 "/src/libpcap/build/grammar.c"
2764
0
    break;
2765
2766
0
  case 136: /* p80211: TYPE type SUBTYPE subtype  */
2767
0
#line 695 "/src/libpcap/build/grammar.y"
2768
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_p80211_type(cstate, (yyvsp[-2].i) | (yyvsp[0].i),
2769
0
          IEEE80211_FC0_TYPE_MASK |
2770
0
          IEEE80211_FC0_SUBTYPE_MASK)));
2771
0
        }
2772
0
#line 2773 "/src/libpcap/build/grammar.c"
2773
0
    break;
2774
2775
0
  case 137: /* p80211: TYPE type  */
2776
0
#line 699 "/src/libpcap/build/grammar.y"
2777
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_p80211_type(cstate, (yyvsp[0].i),
2778
0
          IEEE80211_FC0_TYPE_MASK)));
2779
0
        }
2780
0
#line 2781 "/src/libpcap/build/grammar.c"
2781
0
    break;
2782
2783
0
  case 138: /* p80211: SUBTYPE type_subtype  */
2784
0
#line 702 "/src/libpcap/build/grammar.y"
2785
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_p80211_type(cstate, (yyvsp[0].i),
2786
0
          IEEE80211_FC0_TYPE_MASK |
2787
0
          IEEE80211_FC0_SUBTYPE_MASK)));
2788
0
        }
2789
0
#line 2790 "/src/libpcap/build/grammar.c"
2790
0
    break;
2791
2792
0
  case 139: /* p80211: DIR dir  */
2793
0
#line 706 "/src/libpcap/build/grammar.y"
2794
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_p80211_fcdir(cstate, (yyvsp[0].i)))); }
2795
0
#line 2796 "/src/libpcap/build/grammar.c"
2796
0
    break;
2797
2798
0
  case 140: /* type: NUM  */
2799
0
#line 709 "/src/libpcap/build/grammar.y"
2800
0
                                { if (((yyvsp[0].h) & (~IEEE80211_FC0_TYPE_MASK)) != 0) {
2801
0
          bpf_set_error(cstate, "invalid 802.11 type value 0x%02x", (yyvsp[0].h));
2802
0
          YYABORT;
2803
0
          }
2804
0
          (yyval.i) = (int)(yyvsp[0].h);
2805
0
        }
2806
0
#line 2807 "/src/libpcap/build/grammar.c"
2807
0
    break;
2808
2809
0
  case 141: /* type: ID  */
2810
0
#line 715 "/src/libpcap/build/grammar.y"
2811
0
                                { CHECK_PTR_VAL((yyvsp[0].s));
2812
0
          (yyval.i) = str2tok((yyvsp[0].s), ieee80211_types);
2813
0
          if ((yyval.i) == -1) {
2814
0
          bpf_set_error(cstate, "unknown 802.11 type name \"%s\"", (yyvsp[0].s));
2815
0
          YYABORT;
2816
0
          }
2817
0
        }
2818
0
#line 2819 "/src/libpcap/build/grammar.c"
2819
0
    break;
2820
2821
0
  case 142: /* subtype: NUM  */
2822
0
#line 724 "/src/libpcap/build/grammar.y"
2823
0
                                { if (((yyvsp[0].h) & (~IEEE80211_FC0_SUBTYPE_MASK)) != 0) {
2824
0
          bpf_set_error(cstate, "invalid 802.11 subtype value 0x%02x", (yyvsp[0].h));
2825
0
          YYABORT;
2826
0
          }
2827
0
          (yyval.i) = (int)(yyvsp[0].h);
2828
0
        }
2829
0
#line 2830 "/src/libpcap/build/grammar.c"
2830
0
    break;
2831
2832
0
  case 143: /* subtype: ID  */
2833
0
#line 730 "/src/libpcap/build/grammar.y"
2834
0
                                { const struct tok *types = NULL;
2835
0
          int i;
2836
0
          CHECK_PTR_VAL((yyvsp[0].s));
2837
0
          for (i = 0;; i++) {
2838
0
          if (ieee80211_type_subtypes[i].tok == NULL) {
2839
            /* Ran out of types */
2840
0
            bpf_set_error(cstate, "unknown 802.11 type");
2841
0
            YYABORT;
2842
0
          }
2843
0
          if ((yyvsp[(-1) - (1)].i) == ieee80211_type_subtypes[i].type) {
2844
0
            types = ieee80211_type_subtypes[i].tok;
2845
0
            break;
2846
0
          }
2847
0
          }
2848
2849
0
          (yyval.i) = str2tok((yyvsp[0].s), types);
2850
0
          if ((yyval.i) == -1) {
2851
0
          bpf_set_error(cstate, "unknown 802.11 subtype name \"%s\"", (yyvsp[0].s));
2852
0
          YYABORT;
2853
0
          }
2854
0
        }
2855
0
#line 2856 "/src/libpcap/build/grammar.c"
2856
0
    break;
2857
2858
0
  case 144: /* type_subtype: ID  */
2859
0
#line 753 "/src/libpcap/build/grammar.y"
2860
0
                                { int i;
2861
0
          CHECK_PTR_VAL((yyvsp[0].s));
2862
0
          for (i = 0;; i++) {
2863
0
          if (ieee80211_type_subtypes[i].tok == NULL) {
2864
            /* Ran out of types */
2865
0
            bpf_set_error(cstate, "unknown 802.11 type name");
2866
0
            YYABORT;
2867
0
          }
2868
0
          (yyval.i) = str2tok((yyvsp[0].s), ieee80211_type_subtypes[i].tok);
2869
0
          if ((yyval.i) != -1) {
2870
0
            (yyval.i) |= ieee80211_type_subtypes[i].type;
2871
0
            break;
2872
0
          }
2873
0
          }
2874
0
        }
2875
0
#line 2876 "/src/libpcap/build/grammar.c"
2876
0
    break;
2877
2878
0
  case 145: /* pllc: LLC  */
2879
0
#line 770 "/src/libpcap/build/grammar.y"
2880
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_llc(cstate))); }
2881
0
#line 2882 "/src/libpcap/build/grammar.c"
2882
0
    break;
2883
2884
0
  case 146: /* pllc: LLC ID  */
2885
0
#line 771 "/src/libpcap/build/grammar.y"
2886
0
                                { CHECK_PTR_VAL((yyvsp[0].s));
2887
0
          if (pcapint_strcasecmp((yyvsp[0].s), "i") == 0) {
2888
0
          CHECK_PTR_VAL(((yyval.rblk) = gen_llc_i(cstate)));
2889
0
          } else if (pcapint_strcasecmp((yyvsp[0].s), "s") == 0) {
2890
0
          CHECK_PTR_VAL(((yyval.rblk) = gen_llc_s(cstate)));
2891
0
          } else if (pcapint_strcasecmp((yyvsp[0].s), "u") == 0) {
2892
0
          CHECK_PTR_VAL(((yyval.rblk) = gen_llc_u(cstate)));
2893
0
          } else {
2894
0
          int subtype;
2895
2896
0
          subtype = str2tok((yyvsp[0].s), llc_s_subtypes);
2897
0
          if (subtype != -1) {
2898
0
            CHECK_PTR_VAL(((yyval.rblk) = gen_llc_s_subtype(cstate, subtype)));
2899
0
          } else {
2900
0
            subtype = str2tok((yyvsp[0].s), llc_u_subtypes);
2901
0
            if (subtype == -1) {
2902
0
              bpf_set_error(cstate, "unknown LLC type name \"%s\"", (yyvsp[0].s));
2903
0
              YYABORT;
2904
0
            }
2905
0
            CHECK_PTR_VAL(((yyval.rblk) = gen_llc_u_subtype(cstate, subtype)));
2906
0
          }
2907
0
          }
2908
0
        }
2909
0
#line 2910 "/src/libpcap/build/grammar.c"
2910
0
    break;
2911
2912
0
  case 147: /* pllc: LLC PF_RNR  */
2913
0
#line 795 "/src/libpcap/build/grammar.y"
2914
0
                                { CHECK_PTR_VAL(((yyval.rblk) = gen_llc_s_subtype(cstate, LLC_RNR))); }
2915
0
#line 2916 "/src/libpcap/build/grammar.c"
2916
0
    break;
2917
2918
0
  case 148: /* dir: NUM  */
2919
0
#line 798 "/src/libpcap/build/grammar.y"
2920
0
                                { if (((yyvsp[0].h) & (~IEEE80211_FC1_DIR_MASK)) != 0) {
2921
0
          bpf_set_error(cstate, "invalid 802.11 direction value 0x%x", (yyvsp[0].h));
2922
0
          YYABORT;
2923
0
          }
2924
0
          (yyval.i) = (int)(yyvsp[0].h);
2925
0
        }
2926
0
#line 2927 "/src/libpcap/build/grammar.c"
2927
0
    break;
2928
2929
0
  case 149: /* dir: ID  */
2930
0
#line 804 "/src/libpcap/build/grammar.y"
2931
0
                                { CHECK_PTR_VAL((yyvsp[0].s));
2932
0
          if (pcapint_strcasecmp((yyvsp[0].s), "nods") == 0)
2933
0
          (yyval.i) = IEEE80211_FC1_DIR_NODS;
2934
0
          else if (pcapint_strcasecmp((yyvsp[0].s), "tods") == 0)
2935
0
          (yyval.i) = IEEE80211_FC1_DIR_TODS;
2936
0
          else if (pcapint_strcasecmp((yyvsp[0].s), "fromds") == 0)
2937
0
          (yyval.i) = IEEE80211_FC1_DIR_FROMDS;
2938
0
          else if (pcapint_strcasecmp((yyvsp[0].s), "dstods") == 0)
2939
0
          (yyval.i) = IEEE80211_FC1_DIR_DSTODS;
2940
0
          else {
2941
0
          bpf_set_error(cstate, "unknown 802.11 direction");
2942
0
          YYABORT;
2943
0
          }
2944
0
        }
2945
0
#line 2946 "/src/libpcap/build/grammar.c"
2946
0
    break;
2947
2948
0
  case 150: /* reason: NUM  */
2949
0
#line 820 "/src/libpcap/build/grammar.y"
2950
0
                                { (yyval.i) = (yyvsp[0].h); }
2951
0
#line 2952 "/src/libpcap/build/grammar.c"
2952
0
    break;
2953
2954
0
  case 151: /* reason: ID  */
2955
0
#line 821 "/src/libpcap/build/grammar.y"
2956
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_INT_VAL(((yyval.i) = pfreason_to_num(cstate, (yyvsp[0].s)))); }
2957
0
#line 2958 "/src/libpcap/build/grammar.c"
2958
0
    break;
2959
2960
0
  case 152: /* action: ID  */
2961
0
#line 824 "/src/libpcap/build/grammar.y"
2962
0
                                { CHECK_PTR_VAL((yyvsp[0].s)); CHECK_INT_VAL(((yyval.i) = pfaction_to_num(cstate, (yyvsp[0].s)))); }
2963
0
#line 2964 "/src/libpcap/build/grammar.c"
2964
0
    break;
2965
2966
0
  case 153: /* relop: '>'  */
2967
0
#line 827 "/src/libpcap/build/grammar.y"
2968
0
                                { (yyval.i) = BPF_JGT; }
2969
0
#line 2970 "/src/libpcap/build/grammar.c"
2970
0
    break;
2971
2972
0
  case 154: /* relop: GEQ  */
2973
0
#line 828 "/src/libpcap/build/grammar.y"
2974
0
                                { (yyval.i) = BPF_JGE; }
2975
0
#line 2976 "/src/libpcap/build/grammar.c"
2976
0
    break;
2977
2978
0
  case 155: /* relop: '='  */
2979
0
#line 829 "/src/libpcap/build/grammar.y"
2980
0
                                { (yyval.i) = BPF_JEQ; }
2981
0
#line 2982 "/src/libpcap/build/grammar.c"
2982
0
    break;
2983
2984
0
  case 156: /* irelop: LEQ  */
2985
0
#line 831 "/src/libpcap/build/grammar.y"
2986
0
                                { (yyval.i) = BPF_JGT; }
2987
0
#line 2988 "/src/libpcap/build/grammar.c"
2988
0
    break;
2989
2990
0
  case 157: /* irelop: '<'  */
2991
0
#line 832 "/src/libpcap/build/grammar.y"
2992
0
                                { (yyval.i) = BPF_JGE; }
2993
0
#line 2994 "/src/libpcap/build/grammar.c"
2994
0
    break;
2995
2996
0
  case 158: /* irelop: NEQ  */
2997
0
#line 833 "/src/libpcap/build/grammar.y"
2998
0
                                { (yyval.i) = BPF_JEQ; }
2999
0
#line 3000 "/src/libpcap/build/grammar.c"
3000
0
    break;
3001
3002
0
  case 159: /* arth: pnum  */
3003
0
#line 835 "/src/libpcap/build/grammar.y"
3004
0
                                { CHECK_PTR_VAL(((yyval.a) = gen_loadi(cstate, (yyvsp[0].h)))); }
3005
0
#line 3006 "/src/libpcap/build/grammar.c"
3006
0
    break;
3007
3008
0
  case 161: /* narth: pname '[' arth ']'  */
3009
0
#line 838 "/src/libpcap/build/grammar.y"
3010
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_load(cstate, (yyvsp[-3].i), (yyvsp[-1].a), 1))); }
3011
0
#line 3012 "/src/libpcap/build/grammar.c"
3012
0
    break;
3013
3014
0
  case 162: /* narth: pname '[' arth ':' NUM ']'  */
3015
0
#line 839 "/src/libpcap/build/grammar.y"
3016
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_load(cstate, (yyvsp[-5].i), (yyvsp[-3].a), (yyvsp[-1].h)))); }
3017
0
#line 3018 "/src/libpcap/build/grammar.c"
3018
0
    break;
3019
3020
0
  case 163: /* narth: arth '+' arth  */
3021
0
#line 840 "/src/libpcap/build/grammar.y"
3022
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_ADD, (yyvsp[-2].a), (yyvsp[0].a)))); }
3023
0
#line 3024 "/src/libpcap/build/grammar.c"
3024
0
    break;
3025
3026
0
  case 164: /* narth: arth '-' arth  */
3027
0
#line 841 "/src/libpcap/build/grammar.y"
3028
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_SUB, (yyvsp[-2].a), (yyvsp[0].a)))); }
3029
0
#line 3030 "/src/libpcap/build/grammar.c"
3030
0
    break;
3031
3032
0
  case 165: /* narth: arth '*' arth  */
3033
0
#line 842 "/src/libpcap/build/grammar.y"
3034
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_MUL, (yyvsp[-2].a), (yyvsp[0].a)))); }
3035
0
#line 3036 "/src/libpcap/build/grammar.c"
3036
0
    break;
3037
3038
0
  case 166: /* narth: arth '/' arth  */
3039
0
#line 843 "/src/libpcap/build/grammar.y"
3040
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_DIV, (yyvsp[-2].a), (yyvsp[0].a)))); }
3041
0
#line 3042 "/src/libpcap/build/grammar.c"
3042
0
    break;
3043
3044
0
  case 167: /* narth: arth '%' arth  */
3045
0
#line 844 "/src/libpcap/build/grammar.y"
3046
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_MOD, (yyvsp[-2].a), (yyvsp[0].a)))); }
3047
0
#line 3048 "/src/libpcap/build/grammar.c"
3048
0
    break;
3049
3050
0
  case 168: /* narth: arth '&' arth  */
3051
0
#line 845 "/src/libpcap/build/grammar.y"
3052
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_AND, (yyvsp[-2].a), (yyvsp[0].a)))); }
3053
0
#line 3054 "/src/libpcap/build/grammar.c"
3054
0
    break;
3055
3056
0
  case 169: /* narth: arth '|' arth  */
3057
0
#line 846 "/src/libpcap/build/grammar.y"
3058
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_OR, (yyvsp[-2].a), (yyvsp[0].a)))); }
3059
0
#line 3060 "/src/libpcap/build/grammar.c"
3060
0
    break;
3061
3062
0
  case 170: /* narth: arth '^' arth  */
3063
0
#line 847 "/src/libpcap/build/grammar.y"
3064
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_XOR, (yyvsp[-2].a), (yyvsp[0].a)))); }
3065
0
#line 3066 "/src/libpcap/build/grammar.c"
3066
0
    break;
3067
3068
0
  case 171: /* narth: arth LSH arth  */
3069
0
#line 848 "/src/libpcap/build/grammar.y"
3070
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_LSH, (yyvsp[-2].a), (yyvsp[0].a)))); }
3071
0
#line 3072 "/src/libpcap/build/grammar.c"
3072
0
    break;
3073
3074
0
  case 172: /* narth: arth RSH arth  */
3075
0
#line 849 "/src/libpcap/build/grammar.y"
3076
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_arth(cstate, BPF_RSH, (yyvsp[-2].a), (yyvsp[0].a)))); }
3077
0
#line 3078 "/src/libpcap/build/grammar.c"
3078
0
    break;
3079
3080
0
  case 173: /* narth: '-' arth  */
3081
0
#line 850 "/src/libpcap/build/grammar.y"
3082
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_neg(cstate, (yyvsp[0].a)))); }
3083
0
#line 3084 "/src/libpcap/build/grammar.c"
3084
0
    break;
3085
3086
0
  case 174: /* narth: paren narth ')'  */
3087
0
#line 851 "/src/libpcap/build/grammar.y"
3088
0
                                        { (yyval.a) = (yyvsp[-1].a); }
3089
0
#line 3090 "/src/libpcap/build/grammar.c"
3090
0
    break;
3091
3092
0
  case 175: /* narth: LEN  */
3093
0
#line 852 "/src/libpcap/build/grammar.y"
3094
0
                                        { CHECK_PTR_VAL(((yyval.a) = gen_loadlen(cstate))); }
3095
0
#line 3096 "/src/libpcap/build/grammar.c"
3096
0
    break;
3097
3098
0
  case 176: /* byteop: '&'  */
3099
0
#line 854 "/src/libpcap/build/grammar.y"
3100
0
                                { (yyval.i) = '&'; }
3101
0
#line 3102 "/src/libpcap/build/grammar.c"
3102
0
    break;
3103
3104
0
  case 177: /* byteop: '|'  */
3105
0
#line 855 "/src/libpcap/build/grammar.y"
3106
0
                                { (yyval.i) = '|'; }
3107
0
#line 3108 "/src/libpcap/build/grammar.c"
3108
0
    break;
3109
3110
0
  case 178: /* byteop: '<'  */
3111
0
#line 856 "/src/libpcap/build/grammar.y"
3112
0
                                { (yyval.i) = '<'; }
3113
0
#line 3114 "/src/libpcap/build/grammar.c"
3114
0
    break;
3115
3116
0
  case 179: /* byteop: '>'  */
3117
0
#line 857 "/src/libpcap/build/grammar.y"
3118
0
                                { (yyval.i) = '>'; }
3119
0
#line 3120 "/src/libpcap/build/grammar.c"
3120
0
    break;
3121
3122
0
  case 180: /* byteop: '='  */
3123
0
#line 858 "/src/libpcap/build/grammar.y"
3124
0
                                { (yyval.i) = '='; }
3125
0
#line 3126 "/src/libpcap/build/grammar.c"
3126
0
    break;
3127
3128
0
  case 182: /* pnum: paren pnum ')'  */
3129
0
#line 861 "/src/libpcap/build/grammar.y"
3130
0
                                { (yyval.h) = (yyvsp[-1].h); }
3131
0
#line 3132 "/src/libpcap/build/grammar.c"
3132
0
    break;
3133
3134
0
  case 183: /* atmtype: LANE  */
3135
0
#line 863 "/src/libpcap/build/grammar.y"
3136
0
                                { (yyval.i) = A_LANE; }
3137
0
#line 3138 "/src/libpcap/build/grammar.c"
3138
0
    break;
3139
3140
0
  case 184: /* atmtype: METAC  */
3141
0
#line 864 "/src/libpcap/build/grammar.y"
3142
0
                                { (yyval.i) = A_METAC; }
3143
0
#line 3144 "/src/libpcap/build/grammar.c"
3144
0
    break;
3145
3146
0
  case 185: /* atmtype: BCC  */
3147
0
#line 865 "/src/libpcap/build/grammar.y"
3148
0
                                { (yyval.i) = A_BCC; }
3149
0
#line 3150 "/src/libpcap/build/grammar.c"
3150
0
    break;
3151
3152
0
  case 186: /* atmtype: OAMF4EC  */
3153
0
#line 866 "/src/libpcap/build/grammar.y"
3154
0
                                { (yyval.i) = A_OAMF4EC; }
3155
0
#line 3156 "/src/libpcap/build/grammar.c"
3156
0
    break;
3157
3158
0
  case 187: /* atmtype: OAMF4SC  */
3159
0
#line 867 "/src/libpcap/build/grammar.y"
3160
0
                                { (yyval.i) = A_OAMF4SC; }
3161
0
#line 3162 "/src/libpcap/build/grammar.c"
3162
0
    break;
3163
3164
0
  case 188: /* atmtype: SC  */
3165
0
#line 868 "/src/libpcap/build/grammar.y"
3166
0
                                { (yyval.i) = A_SC; }
3167
0
#line 3168 "/src/libpcap/build/grammar.c"
3168
0
    break;
3169
3170
0
  case 189: /* atmtype: ILMIC  */
3171
0
#line 869 "/src/libpcap/build/grammar.y"
3172
0
                                { (yyval.i) = A_ILMIC; }
3173
0
#line 3174 "/src/libpcap/build/grammar.c"
3174
0
    break;
3175
3176
0
  case 190: /* atmmultitype: OAM  */
3177
0
#line 871 "/src/libpcap/build/grammar.y"
3178
0
                                { (yyval.i) = A_OAM; }
3179
0
#line 3180 "/src/libpcap/build/grammar.c"
3180
0
    break;
3181
3182
0
  case 191: /* atmmultitype: OAMF4  */
3183
0
#line 872 "/src/libpcap/build/grammar.y"
3184
0
                                { (yyval.i) = A_OAMF4; }
3185
0
#line 3186 "/src/libpcap/build/grammar.c"
3186
0
    break;
3187
3188
0
  case 192: /* atmmultitype: CONNECTMSG  */
3189
0
#line 873 "/src/libpcap/build/grammar.y"
3190
0
                                { (yyval.i) = A_CONNECTMSG; }
3191
0
#line 3192 "/src/libpcap/build/grammar.c"
3192
0
    break;
3193
3194
0
  case 193: /* atmmultitype: METACONNECT  */
3195
0
#line 874 "/src/libpcap/build/grammar.y"
3196
0
                                { (yyval.i) = A_METACONNECT; }
3197
0
#line 3198 "/src/libpcap/build/grammar.c"
3198
0
    break;
3199
3200
0
  case 194: /* atmfield: VPI  */
3201
0
#line 877 "/src/libpcap/build/grammar.y"
3202
0
                                { (yyval.blk).atmfieldtype = A_VPI; }
3203
0
#line 3204 "/src/libpcap/build/grammar.c"
3204
0
    break;
3205
3206
0
  case 195: /* atmfield: VCI  */
3207
0
#line 878 "/src/libpcap/build/grammar.y"
3208
0
                                { (yyval.blk).atmfieldtype = A_VCI; }
3209
0
#line 3210 "/src/libpcap/build/grammar.c"
3210
0
    break;
3211
3212
0
  case 197: /* atmvalue: relop NUM  */
3213
0
#line 881 "/src/libpcap/build/grammar.y"
3214
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_atmfield_code(cstate, (yyvsp[-2].blk).atmfieldtype, (yyvsp[0].h), (yyvsp[-1].i), 0))); }
3215
0
#line 3216 "/src/libpcap/build/grammar.c"
3216
0
    break;
3217
3218
0
  case 198: /* atmvalue: irelop NUM  */
3219
0
#line 882 "/src/libpcap/build/grammar.y"
3220
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_atmfield_code(cstate, (yyvsp[-2].blk).atmfieldtype, (yyvsp[0].h), (yyvsp[-1].i), 1))); }
3221
0
#line 3222 "/src/libpcap/build/grammar.c"
3222
0
    break;
3223
3224
0
  case 199: /* atmvalue: paren atmlistvalue ')'  */
3225
0
#line 883 "/src/libpcap/build/grammar.y"
3226
0
                                 { (yyval.blk).b = (yyvsp[-1].blk).b; (yyval.blk).q = qerr; }
3227
0
#line 3228 "/src/libpcap/build/grammar.c"
3228
0
    break;
3229
3230
0
  case 200: /* atmfieldvalue: NUM  */
3231
0
#line 885 "/src/libpcap/build/grammar.y"
3232
0
                   {
3233
0
  (yyval.blk).atmfieldtype = (yyvsp[-1].blk).atmfieldtype;
3234
0
  if ((yyval.blk).atmfieldtype == A_VPI ||
3235
0
      (yyval.blk).atmfieldtype == A_VCI)
3236
0
    CHECK_PTR_VAL(((yyval.blk).b = gen_atmfield_code(cstate, (yyval.blk).atmfieldtype, (yyvsp[0].h), BPF_JEQ, 0)));
3237
0
  }
3238
0
#line 3239 "/src/libpcap/build/grammar.c"
3239
0
    break;
3240
3241
0
  case 202: /* atmlistvalue: atmlistvalue or atmfieldvalue  */
3242
0
#line 893 "/src/libpcap/build/grammar.y"
3243
0
                                        { (yyvsp[0].blk).b = gen_or((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
3244
0
#line 3245 "/src/libpcap/build/grammar.c"
3245
0
    break;
3246
3247
0
  case 203: /* mtp2type: FISU  */
3248
0
#line 896 "/src/libpcap/build/grammar.y"
3249
0
                                { (yyval.i) = M_FISU; }
3250
0
#line 3251 "/src/libpcap/build/grammar.c"
3251
0
    break;
3252
3253
0
  case 204: /* mtp2type: LSSU  */
3254
0
#line 897 "/src/libpcap/build/grammar.y"
3255
0
                                { (yyval.i) = M_LSSU; }
3256
0
#line 3257 "/src/libpcap/build/grammar.c"
3257
0
    break;
3258
3259
0
  case 205: /* mtp2type: MSU  */
3260
0
#line 898 "/src/libpcap/build/grammar.y"
3261
0
                                { (yyval.i) = M_MSU; }
3262
0
#line 3263 "/src/libpcap/build/grammar.c"
3263
0
    break;
3264
3265
0
  case 206: /* mtp2type: HFISU  */
3266
0
#line 899 "/src/libpcap/build/grammar.y"
3267
0
                                { (yyval.i) = MH_FISU; }
3268
0
#line 3269 "/src/libpcap/build/grammar.c"
3269
0
    break;
3270
3271
0
  case 207: /* mtp2type: HLSSU  */
3272
0
#line 900 "/src/libpcap/build/grammar.y"
3273
0
                                { (yyval.i) = MH_LSSU; }
3274
0
#line 3275 "/src/libpcap/build/grammar.c"
3275
0
    break;
3276
3277
0
  case 208: /* mtp2type: HMSU  */
3278
0
#line 901 "/src/libpcap/build/grammar.y"
3279
0
                                { (yyval.i) = MH_MSU; }
3280
0
#line 3281 "/src/libpcap/build/grammar.c"
3281
0
    break;
3282
3283
0
  case 209: /* mtp3field: SIO  */
3284
0
#line 904 "/src/libpcap/build/grammar.y"
3285
0
                                { (yyval.blk).mtp3fieldtype = M_SIO; }
3286
0
#line 3287 "/src/libpcap/build/grammar.c"
3287
0
    break;
3288
3289
0
  case 210: /* mtp3field: OPC  */
3290
0
#line 905 "/src/libpcap/build/grammar.y"
3291
0
                                { (yyval.blk).mtp3fieldtype = M_OPC; }
3292
0
#line 3293 "/src/libpcap/build/grammar.c"
3293
0
    break;
3294
3295
0
  case 211: /* mtp3field: DPC  */
3296
0
#line 906 "/src/libpcap/build/grammar.y"
3297
0
                                { (yyval.blk).mtp3fieldtype = M_DPC; }
3298
0
#line 3299 "/src/libpcap/build/grammar.c"
3299
0
    break;
3300
3301
0
  case 212: /* mtp3field: SLS  */
3302
0
#line 907 "/src/libpcap/build/grammar.y"
3303
0
                                { (yyval.blk).mtp3fieldtype = M_SLS; }
3304
0
#line 3305 "/src/libpcap/build/grammar.c"
3305
0
    break;
3306
3307
0
  case 213: /* mtp3field: HSIO  */
3308
0
#line 908 "/src/libpcap/build/grammar.y"
3309
0
                                { (yyval.blk).mtp3fieldtype = MH_SIO; }
3310
0
#line 3311 "/src/libpcap/build/grammar.c"
3311
0
    break;
3312
3313
0
  case 214: /* mtp3field: HOPC  */
3314
0
#line 909 "/src/libpcap/build/grammar.y"
3315
0
                                { (yyval.blk).mtp3fieldtype = MH_OPC; }
3316
0
#line 3317 "/src/libpcap/build/grammar.c"
3317
0
    break;
3318
3319
0
  case 215: /* mtp3field: HDPC  */
3320
0
#line 910 "/src/libpcap/build/grammar.y"
3321
0
                                { (yyval.blk).mtp3fieldtype = MH_DPC; }
3322
0
#line 3323 "/src/libpcap/build/grammar.c"
3323
0
    break;
3324
3325
0
  case 216: /* mtp3field: HSLS  */
3326
0
#line 911 "/src/libpcap/build/grammar.y"
3327
0
                                { (yyval.blk).mtp3fieldtype = MH_SLS; }
3328
0
#line 3329 "/src/libpcap/build/grammar.c"
3329
0
    break;
3330
3331
0
  case 218: /* mtp3value: relop NUM  */
3332
0
#line 914 "/src/libpcap/build/grammar.y"
3333
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_mtp3field_code(cstate, (yyvsp[-2].blk).mtp3fieldtype, (yyvsp[0].h), (yyvsp[-1].i), 0))); }
3334
0
#line 3335 "/src/libpcap/build/grammar.c"
3335
0
    break;
3336
3337
0
  case 219: /* mtp3value: irelop NUM  */
3338
0
#line 915 "/src/libpcap/build/grammar.y"
3339
0
                                { CHECK_PTR_VAL(((yyval.blk).b = gen_mtp3field_code(cstate, (yyvsp[-2].blk).mtp3fieldtype, (yyvsp[0].h), (yyvsp[-1].i), 1))); }
3340
0
#line 3341 "/src/libpcap/build/grammar.c"
3341
0
    break;
3342
3343
0
  case 220: /* mtp3value: paren mtp3listvalue ')'  */
3344
0
#line 916 "/src/libpcap/build/grammar.y"
3345
0
                                  { (yyval.blk).b = (yyvsp[-1].blk).b; (yyval.blk).q = qerr; }
3346
0
#line 3347 "/src/libpcap/build/grammar.c"
3347
0
    break;
3348
3349
0
  case 221: /* mtp3fieldvalue: NUM  */
3350
0
#line 918 "/src/libpcap/build/grammar.y"
3351
0
                    {
3352
0
  (yyval.blk).mtp3fieldtype = (yyvsp[-1].blk).mtp3fieldtype;
3353
0
  if ((yyval.blk).mtp3fieldtype == M_SIO ||
3354
0
      (yyval.blk).mtp3fieldtype == M_OPC ||
3355
0
      (yyval.blk).mtp3fieldtype == M_DPC ||
3356
0
      (yyval.blk).mtp3fieldtype == M_SLS ||
3357
0
      (yyval.blk).mtp3fieldtype == MH_SIO ||
3358
0
      (yyval.blk).mtp3fieldtype == MH_OPC ||
3359
0
      (yyval.blk).mtp3fieldtype == MH_DPC ||
3360
0
      (yyval.blk).mtp3fieldtype == MH_SLS)
3361
0
    CHECK_PTR_VAL(((yyval.blk).b = gen_mtp3field_code(cstate, (yyval.blk).mtp3fieldtype, (yyvsp[0].h), BPF_JEQ, 0)));
3362
0
  }
3363
0
#line 3364 "/src/libpcap/build/grammar.c"
3364
0
    break;
3365
3366
0
  case 223: /* mtp3listvalue: mtp3listvalue or mtp3fieldvalue  */
3367
0
#line 932 "/src/libpcap/build/grammar.y"
3368
0
                                          { (yyvsp[0].blk).b = gen_or((yyvsp[-2].blk).b, (yyvsp[0].blk).b); (yyval.blk) = (yyvsp[0].blk); }
3369
0
#line 3370 "/src/libpcap/build/grammar.c"
3370
0
    break;
3371
3372
3373
0
#line 3374 "/src/libpcap/build/grammar.c"
3374
3375
0
      default: break;
3376
0
    }
3377
  /* User semantic actions sometimes alter yychar, and that requires
3378
     that yytoken be updated with the new translation.  We take the
3379
     approach of translating immediately before every use of yytoken.
3380
     One alternative is translating here after every semantic action,
3381
     but that translation would be missed if the semantic action invokes
3382
     YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
3383
     if it invokes YYBACKUP.  In the case of YYABORT or YYACCEPT, an
3384
     incorrect destructor might then be invoked immediately.  In the
3385
     case of YYERROR or YYBACKUP, subsequent parser actions might lead
3386
     to an incorrect destructor call or verbose syntax error message
3387
     before the lookahead is translated.  */
3388
0
  YY_SYMBOL_PRINT ("-> $$ =", YY_CAST (yysymbol_kind_t, yyr1[yyn]), &yyval, &yyloc);
3389
3390
0
  YYPOPSTACK (yylen);
3391
0
  yylen = 0;
3392
3393
0
  *++yyvsp = yyval;
3394
3395
  /* Now 'shift' the result of the reduction.  Determine what state
3396
     that goes to, based on the state we popped back to and the rule
3397
     number reduced by.  */
3398
0
  {
3399
0
    const int yylhs = yyr1[yyn] - YYNTOKENS;
3400
0
    const int yyi = yypgoto[yylhs] + *yyssp;
3401
0
    yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
3402
0
               ? yytable[yyi]
3403
0
               : yydefgoto[yylhs]);
3404
0
  }
3405
3406
0
  goto yynewstate;
3407
3408
3409
/*--------------------------------------.
3410
| yyerrlab -- here on detecting error.  |
3411
`--------------------------------------*/
3412
0
yyerrlab:
3413
  /* Make sure we have latest lookahead translation.  See comments at
3414
     user semantic actions for why this is necessary.  */
3415
0
  yytoken = yychar == YYEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar);
3416
  /* If not already recovering from an error, report this error.  */
3417
0
  if (!yyerrstatus)
3418
0
    {
3419
0
      ++yynerrs;
3420
0
      yyerror (yyscanner, cstate, YY_("syntax error"));
3421
0
    }
3422
3423
0
  if (yyerrstatus == 3)
3424
0
    {
3425
      /* If just tried and failed to reuse lookahead token after an
3426
         error, discard it.  */
3427
3428
0
      if (yychar <= YYEOF)
3429
0
        {
3430
          /* Return failure if at end of input.  */
3431
0
          if (yychar == YYEOF)
3432
0
            YYABORT;
3433
0
        }
3434
0
      else
3435
0
        {
3436
0
          yydestruct ("Error: discarding",
3437
0
                      yytoken, &yylval, yyscanner, cstate);
3438
0
          yychar = YYEMPTY;
3439
0
        }
3440
0
    }
3441
3442
  /* Else will try to reuse lookahead token after shifting the error
3443
     token.  */
3444
0
  goto yyerrlab1;
3445
3446
3447
/*---------------------------------------------------.
3448
| yyerrorlab -- error raised explicitly by YYERROR.  |
3449
`---------------------------------------------------*/
3450
0
yyerrorlab:
3451
  /* Pacify compilers when the user code never invokes YYERROR and the
3452
     label yyerrorlab therefore never appears in user code.  */
3453
0
  if (0)
3454
0
    YYERROR;
3455
0
  ++yynerrs;
3456
3457
  /* Do not reclaim the symbols of the rule whose action triggered
3458
     this YYERROR.  */
3459
0
  YYPOPSTACK (yylen);
3460
0
  yylen = 0;
3461
0
  YY_STACK_PRINT (yyss, yyssp);
3462
0
  yystate = *yyssp;
3463
0
  goto yyerrlab1;
3464
3465
3466
/*-------------------------------------------------------------.
3467
| yyerrlab1 -- common code for both syntax error and YYERROR.  |
3468
`-------------------------------------------------------------*/
3469
0
yyerrlab1:
3470
0
  yyerrstatus = 3;      /* Each real token shifted decrements this.  */
3471
3472
  /* Pop stack until we find a state that shifts the error token.  */
3473
0
  for (;;)
3474
0
    {
3475
0
      yyn = yypact[yystate];
3476
0
      if (!yypact_value_is_default (yyn))
3477
0
        {
3478
0
          yyn += YYSYMBOL_YYerror;
3479
0
          if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror)
3480
0
            {
3481
0
              yyn = yytable[yyn];
3482
0
              if (0 < yyn)
3483
0
                break;
3484
0
            }
3485
0
        }
3486
3487
      /* Pop the current state because it cannot handle the error token.  */
3488
0
      if (yyssp == yyss)
3489
0
        YYABORT;
3490
3491
3492
0
      yydestruct ("Error: popping",
3493
0
                  YY_ACCESSING_SYMBOL (yystate), yyvsp, yyscanner, cstate);
3494
0
      YYPOPSTACK (1);
3495
0
      yystate = *yyssp;
3496
0
      YY_STACK_PRINT (yyss, yyssp);
3497
0
    }
3498
3499
0
  YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
3500
0
  *++yyvsp = yylval;
3501
0
  YY_IGNORE_MAYBE_UNINITIALIZED_END
3502
3503
3504
  /* Shift the error token.  */
3505
0
  YY_SYMBOL_PRINT ("Shifting", YY_ACCESSING_SYMBOL (yyn), yyvsp, yylsp);
3506
3507
0
  yystate = yyn;
3508
0
  goto yynewstate;
3509
3510
3511
/*-------------------------------------.
3512
| yyacceptlab -- YYACCEPT comes here.  |
3513
`-------------------------------------*/
3514
0
yyacceptlab:
3515
0
  yyresult = 0;
3516
0
  goto yyreturnlab;
3517
3518
3519
/*-----------------------------------.
3520
| yyabortlab -- YYABORT comes here.  |
3521
`-----------------------------------*/
3522
0
yyabortlab:
3523
0
  yyresult = 1;
3524
0
  goto yyreturnlab;
3525
3526
3527
/*-----------------------------------------------------------.
3528
| yyexhaustedlab -- YYNOMEM (memory exhaustion) comes here.  |
3529
`-----------------------------------------------------------*/
3530
0
yyexhaustedlab:
3531
0
  yyerror (yyscanner, cstate, YY_("memory exhausted"));
3532
0
  yyresult = 2;
3533
0
  goto yyreturnlab;
3534
3535
3536
/*----------------------------------------------------------.
3537
| yyreturnlab -- parsing is finished, clean up and return.  |
3538
`----------------------------------------------------------*/
3539
0
yyreturnlab:
3540
0
  if (yychar != YYEMPTY)
3541
0
    {
3542
      /* Make sure we have latest lookahead translation.  See comments at
3543
         user semantic actions for why this is necessary.  */
3544
0
      yytoken = YYTRANSLATE (yychar);
3545
0
      yydestruct ("Cleanup: discarding lookahead",
3546
0
                  yytoken, &yylval, yyscanner, cstate);
3547
0
    }
3548
  /* Do not reclaim the symbols of the rule whose action triggered
3549
     this YYABORT or YYACCEPT.  */
3550
0
  YYPOPSTACK (yylen);
3551
0
  YY_STACK_PRINT (yyss, yyssp);
3552
0
  while (yyssp != yyss)
3553
0
    {
3554
0
      yydestruct ("Cleanup: popping",
3555
0
                  YY_ACCESSING_SYMBOL (+*yyssp), yyvsp, yyscanner, cstate);
3556
0
      YYPOPSTACK (1);
3557
0
    }
3558
0
#ifndef yyoverflow
3559
0
  if (yyss != yyssa)
3560
0
    YYSTACK_FREE (yyss);
3561
0
#endif
3562
3563
0
  return yyresult;
3564
0
}
3565
3566
#line 934 "/src/libpcap/build/grammar.y"
3567