enum yytokentype {
CLOSE = 258,
CLOSESIZE = 259,
- CODE = 260,
+ TOKEN_CODE = 260,
CONF = 261,
ID = 262,
FID = 263,
First, the terminals, then, starting at YYNTOKENS, nonterminals. */
static const char *const yytname[] =
{
- "$end", "error", "$undefined", "CLOSE", "CLOSESIZE", "CODE", "CONF",
- "ID", "FID", "FID_END", "NOCOND", "REGEXP", "SETUP", "STAR", "'='",
- "';'", "'/'", "'<'", "'>'", "':'", "','", "'|'", "'\\\\'", "'('", "')'",
- "$accept", "spec", "decl", "rule", "cond", "clist", "newcond", "look",
- "expr", "diff", "term", "factor", "close", "primary", 0
+ "$end", "error", "$undefined", "CLOSE", "CLOSESIZE", "TOKEN_CODE",
+ "CONF", "ID", "FID", "FID_END", "NOCOND", "REGEXP", "SETUP", "STAR",
+ "'='", "';'", "'/'", "'<'", "'>'", "':'", "','", "'|'", "'\\\\'", "'('",
+ "')'", "$accept", "spec", "decl", "rule", "cond", "clist", "newcond",
+ "look", "expr", "diff", "term", "factor", "close", "primary", 0
};
#endif
%token CLOSE
%token CLOSESIZE
-%token CODE
+%token TOKEN_CODE
%token CONF
%token ID
%token FID
%type <op> CLOSE STAR SETUP close
%type <extop> CLOSESIZE
-%type <code> CODE
+%type <code> TOKEN_CODE
%type <regexp> REGEXP rule look expr diff term factor primary
%type <str> ID FID newcond
%type <clist> cond clist
;
rule:
- expr look CODE
+ expr look TOKEN_CODE
{
if (opts->cFlag)
{
);
spec.add (rule);
}
- | STAR CODE /* default rule */
+ | STAR TOKEN_CODE /* default rule */
{
if (opts->cFlag)
in->fatal("condition or '<*>' required when using -c switch");
in->fatal("code to default rule is already defined");
}
}
- | '<' cond '>' expr look newcond CODE
+ | '<' cond '>' expr look newcond TOKEN_CODE
{
context_rule ($2, $7->loc, $4, $5, $7, $6);
}
Loc loc (in->get_fname (), in->get_cline ());
context_rule ($2, loc, $4, $5, NULL, $7);
}
- | '<' cond '>' look newcond CODE
+ | '<' cond '>' look newcond TOKEN_CODE
{
context_none($2);
delete $5;
context_none($2);
delete $6;
}
- | '<' cond '>' STAR CODE /* default rule for conditions */
+ | '<' cond '>' STAR TOKEN_CODE /* default rule for conditions */
{
default_rule($2, $5);
}
- | '<' STAR '>' expr look newcond CODE
+ | '<' STAR '>' expr look newcond TOKEN_CODE
{
context_check(NULL);
RuleOp * rule = new RuleOp
specStar.push_back (rule);
delete $7;
}
- | '<' STAR '>' look newcond CODE
+ | '<' STAR '>' look newcond TOKEN_CODE
{
context_none(NULL);
delete $5;
context_none(NULL);
delete $6;
}
- | '<' STAR '>' STAR CODE /* default rule for all conditions */
+ | '<' STAR '>' STAR TOKEN_CODE /* default rule for all conditions */
{
if (star_default)
{
, NULL
);
}
- | NOCOND newcond CODE
+ | NOCOND newcond TOKEN_CODE
{
context_check(NULL);
if (specNone)
);
delete $3;
}
- | SETUP STAR '>' CODE
+ | SETUP STAR '>' TOKEN_CODE
{
CondList *clist = new CondList();
clist->insert("*");
setup_rule(clist, $4);
}
- | SETUP cond '>' CODE
+ | SETUP cond '>' TOKEN_CODE
{
setup_rule($2, $4);
}