/* Generated by re2c */ /* $Id$ */ #include #include #include #include #include "scanner.h" #include "parser.h" #include "y.tab.h" #include "globals.h" #include "dfa.h" extern YYSTYPE yylval; #ifndef MAX #define MAX(a,b) (((a)>(b))?(a):(b)) #endif #define YYCTYPE unsigned char #define YYCURSOR cursor #define YYLIMIT lim #define YYMARKER ptr #define YYCTXMARKER ctx #define YYFILL(n) {cursor = fill(cursor, n);} #define RETURN(i) {cur = cursor; return i;} namespace re2c { Scanner::ParseMode Scanner::echo() { char *cursor = cur; bool ignore_eoc = false; int ignore_cnt = 0; if (eof && cursor == eof) // Catch EOF { return Stop; } tok = cursor; echo: { YYCTYPE yych; unsigned int yyaccept = 0; static const unsigned char yybm[] = { 128, 128, 128, 128, 128, 128, 128, 128, 128, 160, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 160, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; if ((YYLIMIT - YYCURSOR) < 16) YYFILL(16); yych = *YYCURSOR; if (yych <= '%') { if (yych <= '\t') { if (yych >= 0x01) goto yy4; } else { if (yych <= '\n') goto yy6; if (yych <= '$') goto yy4; goto yy8; } } else { if (yych <= '*') { if (yych <= ')') goto yy4; goto yy9; } else { if (yych == '/') goto yy10; goto yy4; } } ++YYCURSOR; { if (!ignore_eoc && !DFlag) { out.write((const char*)(tok), (const char*)(cursor) - (const char*)(tok) - 1); // -1 so we don't write out the \0 } if(cursor == eof) { RETURN(Stop); } } yy4: ++YYCURSOR; yy5: { goto echo; } yy6: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yybm[0+yych] & 32) { goto yy11; } if (yych == '#') goto yy14; yy7: { if (ignore_eoc) { ignore_cnt++; } else if (!DFlag) { out.write((const char*)(tok), (const char*)(cursor) - (const char*)(tok)); } tok = pos = cursor; cline++; goto echo; } yy8: yych = *++YYCURSOR; if (yych == '{') goto yy16; goto yy5; yy9: yych = *++YYCURSOR; if (yych == '/') goto yy18; goto yy5; yy10: yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if (yych == '*') goto yy20; goto yy5; yy11: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 32) { goto yy11; } if (yych == '#') goto yy14; yy13: YYCURSOR = YYMARKER; if (yyaccept <= 1) { if (yyaccept == 0) { goto yy7; } else { goto yy5; } } else { goto yy19; } yy14: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy14; goto yy13; } else { if (yych <= ' ') goto yy14; if (yych == 'l') goto yy21; goto yy13; } yy16: ++YYCURSOR; { if (rFlag) { fatal("found standard 're2c' block while using -r flag"); } if (bUsedYYMaxFill && bSinglePass) { fatal("found scanner block after YYMAXFILL declaration"); } if (!DFlag) { out.write((const char*)(tok), (const char*)(&cursor[-7]) - (const char*)(tok)); } tok = cursor; RETURN(Parse); } yy18: yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); if (yych == '\n') goto yy22; if (yych == '\r') goto yy24; yy19: { if (ignore_eoc) { if (ignore_cnt) { out << "\n" << sourceFileInfo; } ignore_eoc = false; ignore_cnt = 0; } else if (!DFlag) { out.write((const char*)(tok), (const char*)(cursor) - (const char*)(tok)); } tok = pos = cursor; goto echo; } yy20: yych = *++YYCURSOR; if (yych == '!') goto yy25; goto yy13; yy21: yych = *++YYCURSOR; if (yych == 'i') goto yy26; goto yy13; yy22: ++YYCURSOR; { cline++; if (ignore_eoc) { if (ignore_cnt) { out << sourceFileInfo; } ignore_eoc = false; ignore_cnt = 0; } else if (!DFlag) { out.write((const char*)(tok), (const char*)(cursor) - (const char*)(tok)); } tok = pos = cursor; goto echo; } yy24: yych = *++YYCURSOR; if (yych == '\n') goto yy22; goto yy13; yy25: yych = *++YYCURSOR; switch (yych) { case 'g': goto yy27; case 'i': goto yy28; case 'm': goto yy29; case 'r': goto yy30; case 't': goto yy31; case 'u': goto yy32; default: goto yy13; } yy26: yych = *++YYCURSOR; if (yych == 'n') goto yy33; goto yy13; yy27: yych = *++YYCURSOR; if (yych == 'e') goto yy34; goto yy13; yy28: yych = *++YYCURSOR; if (yych == 'g') goto yy35; goto yy13; yy29: yych = *++YYCURSOR; if (yych == 'a') goto yy36; goto yy13; yy30: yych = *++YYCURSOR; if (yych == 'e') goto yy37; if (yych == 'u') goto yy38; goto yy13; yy31: yych = *++YYCURSOR; if (yych == 'y') goto yy39; goto yy13; yy32: yych = *++YYCURSOR; if (yych == 's') goto yy40; goto yy13; yy33: yych = *++YYCURSOR; if (yych == 'e') goto yy41; goto yy13; yy34: yych = *++YYCURSOR; if (yych == 't') goto yy42; goto yy13; yy35: yych = *++YYCURSOR; if (yych == 'n') goto yy43; goto yy13; yy36: yych = *++YYCURSOR; if (yych == 'x') goto yy44; goto yy13; yy37: yych = *++YYCURSOR; if (yych == '2') goto yy45; goto yy13; yy38: yych = *++YYCURSOR; if (yych == 'l') goto yy46; goto yy13; yy39: yych = *++YYCURSOR; if (yych == 'p') goto yy47; goto yy13; yy40: yych = *++YYCURSOR; if (yych == 'e') goto yy48; goto yy13; yy41: yych = *++YYCURSOR; if (yych <= '0') goto yy50; if (yych <= '9') goto yy13; goto yy50; yy42: yych = *++YYCURSOR; if (yych == 's') goto yy51; goto yy13; yy43: yych = *++YYCURSOR; if (yych == 'o') goto yy52; goto yy13; yy44: yych = *++YYCURSOR; if (yych == ':') goto yy53; goto yy13; yy45: yych = *++YYCURSOR; if (yych == 'c') goto yy16; goto yy13; yy46: yych = *++YYCURSOR; if (yych == 'e') goto yy54; goto yy13; yy47: yych = *++YYCURSOR; if (yych == 'e') goto yy55; goto yy13; yy48: yych = *++YYCURSOR; if (yych == ':') goto yy56; goto yy13; yy49: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy50: if (yych <= 0x1F) { if (yych == '\t') goto yy49; goto yy13; } else { if (yych <= ' ') goto yy49; if (yych <= '0') goto yy13; if (yych <= '9') { YYCTXMARKER = YYCURSOR; goto yy57; } goto yy13; } yy51: yych = *++YYCURSOR; if (yych == 't') goto yy59; goto yy13; yy52: yych = *++YYCURSOR; if (yych == 'r') goto yy60; goto yy13; yy53: yych = *++YYCURSOR; if (yych == 'r') goto yy61; goto yy13; yy54: yych = *++YYCURSOR; if (yych == 's') goto yy62; goto yy13; yy55: yych = *++YYCURSOR; if (yych == 's') goto yy63; goto yy13; yy56: yych = *++YYCURSOR; if (yych == 'r') goto yy64; goto yy13; yy57: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yybm[0+yych] & 64) { goto yy57; } if (yych <= '\f') { if (yych <= 0x08) goto yy13; if (yych <= '\t') goto yy65; if (yych <= '\n') goto yy67; goto yy13; } else { if (yych <= '\r') goto yy69; if (yych == ' ') goto yy65; goto yy13; } yy59: yych = *++YYCURSOR; if (yych == 'a') goto yy70; goto yy13; yy60: yych = *++YYCURSOR; if (yych == 'e') goto yy71; goto yy13; yy61: yych = *++YYCURSOR; if (yych == 'e') goto yy72; goto yy13; yy62: yych = *++YYCURSOR; if (yych == ':') goto yy73; goto yy13; yy63: yych = *++YYCURSOR; if (yych == ':') goto yy74; goto yy13; yy64: yych = *++YYCURSOR; if (yych == 'e') goto yy75; goto yy13; yy65: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy65; goto yy13; } else { if (yych <= ' ') goto yy65; if (yych == '"') goto yy76; goto yy13; } yy67: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { set_sourceline(cursor); goto echo; } yy69: yych = *++YYCURSOR; if (yych == '\n') goto yy67; goto yy13; yy70: yych = *++YYCURSOR; if (yych == 't') goto yy78; goto yy13; yy71: yych = *++YYCURSOR; if (yych == ':') goto yy79; goto yy13; yy72: yych = *++YYCURSOR; if (yych == '2') goto yy80; goto yy13; yy73: yych = *++YYCURSOR; if (yych == 'r') goto yy81; goto yy13; yy74: yych = *++YYCURSOR; if (yych == 'r') goto yy82; goto yy13; yy75: yych = *++YYCURSOR; if (yych == '2') goto yy83; goto yy13; yy76: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3); yych = *YYCURSOR; if (yybm[0+yych] & 128) { goto yy76; } if (yych <= '\n') goto yy13; if (yych <= '"') goto yy84; goto yy85; yy78: yych = *++YYCURSOR; if (yych == 'e') goto yy86; goto yy13; yy79: yych = *++YYCURSOR; if (yych == 'r') goto yy87; goto yy13; yy80: yych = *++YYCURSOR; if (yych == 'c') goto yy88; goto yy13; yy81: yych = *++YYCURSOR; if (yych == 'e') goto yy90; goto yy13; yy82: yych = *++YYCURSOR; if (yych == 'e') goto yy91; goto yy13; yy83: yych = *++YYCURSOR; if (yych == 'c') goto yy92; goto yy13; yy84: yych = *++YYCURSOR; if (yych == '\n') goto yy67; if (yych == '\r') goto yy69; goto yy13; yy85: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy13; goto yy76; yy86: yych = *++YYCURSOR; if (yych == ':') goto yy94; goto yy13; yy87: yych = *++YYCURSOR; if (yych == 'e') goto yy95; goto yy13; yy88: ++YYCURSOR; { if (bUsedYYMaxFill) { fatal("cannot generate YYMAXFILL twice"); } if (!DFlag) { out << "#define YYMAXFILL " << maxFill << std::endl; } tok = pos = cursor; ignore_eoc = true; bUsedYYMaxFill = true; goto echo; } yy90: yych = *++YYCURSOR; if (yych == '2') goto yy96; goto yy13; yy91: yych = *++YYCURSOR; if (yych == '2') goto yy97; goto yy13; yy92: ++YYCURSOR; { if (!rFlag) { fatal("found 'use:re2c' block without -r flag"); } reuse(); if (bUsedYYMaxFill && bSinglePass) { fatal("found scanner block after YYMAXFILL declaration"); } if (!DFlag) { out.write((const char*)(tok), (const char*)(&cursor[-11]) - (const char*)(tok)); } tok = cursor; RETURN(Reuse); } yy94: yych = *++YYCURSOR; if (yych == 'r') goto yy98; goto yy13; yy95: yych = *++YYCURSOR; if (yych == '2') goto yy99; goto yy13; yy96: yych = *++YYCURSOR; if (yych == 'c') goto yy100; goto yy13; yy97: yych = *++YYCURSOR; if (yych == 'c') goto yy102; goto yy13; yy98: yych = *++YYCURSOR; if (yych == 'e') goto yy104; goto yy13; yy99: yych = *++YYCURSOR; if (yych == 'c') goto yy105; goto yy13; yy100: ++YYCURSOR; { if (rFlag) { mapCodeName.clear(); } else { fatal("found 'rules:re2c' block without -r flag"); } if (bUsedYYMaxFill && bSinglePass) { fatal("found scanner block after YYMAXFILL declaration"); } tok = cursor; RETURN(Rules); } yy102: ++YYCURSOR; { if (bSinglePass) { fatal("cannot generate types inline in single pass mode"); } tok = pos = cursor; ignore_eoc = true; if (bLastPass && !DFlag) { out << outputFileInfo; out << "\n"; out << typesInline; out << "\n"; out << sourceFileInfo; } goto echo; } yy104: yych = *++YYCURSOR; if (yych == '2') goto yy107; goto yy13; yy105: ++YYCURSOR; { tok = pos = cursor; ignore_eoc = true; goto echo; } yy107: yych = *++YYCURSOR; if (yych != 'c') goto yy13; ++YYCURSOR; { tok = pos = cursor; genGetStateGoto(out, topIndent, 0); ignore_eoc = true; goto echo; } } } int Scanner::scan() { char *cursor = cur; uint depth; scan: tchar = cursor - pos; tline = cline; tok = cursor; if (iscfg == 1) { goto config; } else if (iscfg == 2) { goto value; } { YYCTYPE yych; unsigned int yyaccept = 0; static const unsigned char yybm[] = { 112, 112, 112, 112, 112, 112, 112, 112, 112, 116, 0, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 116, 112, 96, 112, 112, 112, 112, 80, 112, 112, 112, 112, 112, 112, 112, 112, 248, 248, 248, 248, 248, 248, 248, 248, 248, 248, 112, 112, 112, 112, 112, 112, 112, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 112, 0, 48, 112, 120, 112, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, 112, }; if ((YYLIMIT - YYCURSOR) < 6) YYFILL(6); yych = *YYCURSOR; if (yybm[0+yych] & 4) { goto yy114; } if (yych <= '9') { if (yych <= '&') { if (yych <= '\r') { if (yych <= 0x08) goto yy112; if (yych <= '\n') goto yy117; if (yych >= '\r') goto yy119; } else { if (yych <= '"') { if (yych >= '"') goto yy120; } else { if (yych == '%') goto yy122; } } } else { if (yych <= '+') { if (yych <= '\'') goto yy123; if (yych <= ')') goto yy125; if (yych <= '*') goto yy127; goto yy129; } else { if (yych <= '-') { if (yych <= ',') goto yy125; } else { if (yych <= '.') goto yy131; if (yych <= '/') goto yy133; } } } } else { if (yych <= '\\') { if (yych <= '>') { if (yych <= ':') goto yy134; if (yych == '<') goto yy135; goto yy125; } else { if (yych <= '@') { if (yych <= '?') goto yy129; } else { if (yych <= 'Z') goto yy136; if (yych <= '[') goto yy138; goto yy125; } } } else { if (yych <= 'q') { if (yych == '_') goto yy136; if (yych >= 'a') goto yy136; } else { if (yych <= 'z') { if (yych <= 'r') goto yy140; goto yy136; } else { if (yych <= '{') goto yy141; if (yych <= '|') goto yy125; } } } } yy112: ++YYCURSOR; yy113: { std::ostringstream msg; msg << "unexpected character: "; prtChOrHex(msg, *tok); fatal(msg.str().c_str()); goto scan; } yy114: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 4) { goto yy114; } { goto scan; } yy117: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 0x1F) { if (yych == '\t') goto yy143; } else { if (yych <= ' ') goto yy143; if (yych == '#') goto yy146; } yy118: { if (cursor == eof) RETURN(0); pos = cursor; cline++; goto scan; } yy119: yych = *++YYCURSOR; if (yych == '\n') goto yy117; goto yy113; yy120: yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if (yych != '\n') goto yy149; yy121: { fatal("unterminated string constant (missing \")"); } yy122: yych = *++YYCURSOR; if (yych == '}') goto yy153; goto yy113; yy123: yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); if (yych != '\n') goto yy156; yy124: { fatal("unterminated string constant (missing ')"); } yy125: ++YYCURSOR; yy126: { RETURN(*tok); } yy127: yych = *++YYCURSOR; if (yych == '/') goto yy153; { yylval.op = *tok; RETURN(STAR); } yy129: ++YYCURSOR; { yylval.op = *tok; RETURN(CLOSE); } yy131: ++YYCURSOR; { cur = cursor; yylval.regexp = mkDot(); return RANGE; } yy133: yych = *++YYCURSOR; if (yych == '*') goto yy160; if (yych == '/') goto yy162; goto yy126; yy134: yych = *++YYCURSOR; if (yych == '=') goto yy164; goto yy113; yy135: yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); if (yych == '!') goto yy166; if (yych == '>') goto yy168; goto yy126; yy136: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy137: if (yybm[0+yych] & 8) { goto yy136; } if (yych <= ' ') { if (yych == '\t') { YYCTXMARKER = YYCURSOR; goto yy171; } if (yych <= 0x1F) goto yy169; YYCTXMARKER = YYCURSOR; goto yy171; } else { if (yych <= ',') { if (yych <= '+') goto yy169; YYCTXMARKER = YYCURSOR; goto yy173; } else { if (yych <= '<') goto yy169; if (yych <= '>') { YYCTXMARKER = YYCURSOR; goto yy173; } goto yy169; } } yy138: yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); if (yych == '\n') goto yy139; if (yych == '^') goto yy180; goto yy176; yy139: { fatal("unterminated range (missing ])"); } yy140: yych = *++YYCURSOR; if (yych == 'e') goto yy182; goto yy137; yy141: yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); if (yych <= '@') { if (yych <= '/') { if (yych == ',') goto yy183; } else { if (yych <= '0') goto yy185; if (yych <= '9') goto yy186; } } else { if (yych <= '_') { if (yych <= 'Z') goto yy188; if (yych >= '_') goto yy188; } else { if (yych <= '`') goto yy142; if (yych <= 'z') goto yy188; } } yy142: { depth = 1; goto code; } yy143: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy143; } else { if (yych <= ' ') goto yy143; if (yych == '#') goto yy146; } yy145: YYCURSOR = YYMARKER; if (yyaccept <= 3) { if (yyaccept <= 1) { if (yyaccept == 0) { goto yy118; } else { goto yy121; } } else { if (yyaccept == 2) { goto yy124; } else { goto yy126; } } } else { if (yyaccept <= 5) { if (yyaccept == 4) { goto yy139; } else { goto yy142; } } else { if (yyaccept == 6) { goto yy184; } else { goto yy226; } } } yy146: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy146; goto yy145; } else { if (yych <= ' ') goto yy146; if (yych == 'l') goto yy190; goto yy145; } yy148: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy149: if (yybm[0+yych] & 16) { goto yy148; } if (yych <= '\n') goto yy145; if (yych >= '#') goto yy152; ++YYCURSOR; { cur = cursor; if (bCaseInsensitive || bCaseInverted) { yylval.regexp = strToCaseInsensitiveRE(token()); } else { yylval.regexp = strToRE(token()); } return STRING; } yy152: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy145; goto yy148; yy153: ++YYCURSOR; { tok = cursor; RETURN(0); } yy155: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy156: if (yybm[0+yych] & 32) { goto yy155; } if (yych <= '\n') goto yy145; if (yych >= '(') goto yy159; ++YYCURSOR; { cur = cursor; if (bCaseInverted) { yylval.regexp = strToRE(token()); } else { yylval.regexp = strToCaseInsensitiveRE(token()); } return STRING; } yy159: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy145; goto yy155; yy160: ++YYCURSOR; { depth = 1; goto comment; } yy162: ++YYCURSOR; { goto nextLine; } yy164: yych = *++YYCURSOR; if (yych == '>') goto yy191; { cur = cursor; tok += 2; /* skip ":=" */ depth = 0; goto code; } yy166: ++YYCURSOR; { RETURN(SETUP); } yy168: yych = *++YYCURSOR; if (yych <= '9') { if (yych <= '\t') { if (yych <= 0x08) goto yy145; YYCTXMARKER = YYCURSOR; goto yy193; } else { if (yych == ' ') { YYCTXMARKER = YYCURSOR; goto yy193; } goto yy145; } } else { if (yych <= '=') { if (yych <= ':') { YYCTXMARKER = YYCURSOR; goto yy195; } if (yych <= '<') goto yy145; YYCTXMARKER = YYCURSOR; goto yy196; } else { if (yych == '{') { YYCTXMARKER = YYCURSOR; goto yy197; } goto yy145; } } yy169: ++YYCURSOR; yy170: YYCURSOR -= 1; { if (!FFlag) { cur = cursor; yylval.symbol = Symbol::find(token()); return ID; } else { /* Add one char in front and one behind instead of 's or "s */ cur = cursor; if (bCaseInsensitive || bCaseInverted) { yylval.regexp = strToCaseInsensitiveRE(raw_token("\"")); } else { yylval.regexp = strToRE(raw_token("\"")); } return STRING; } } yy171: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= ' ') { if (yych == '\t') goto yy171; if (yych <= 0x1F) goto yy199; goto yy171; } else { if (yych <= ',') { if (yych <= '+') goto yy199; } else { if (yych <= '<') goto yy199; if (yych >= '?') goto yy199; } } yy173: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { cur = ptr > tok ? ptr - 1 : cursor; yylval.symbol = Symbol::find(token()); return ID; } yy175: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy176: if (yybm[0+yych] & 64) { goto yy175; } if (yych <= '\n') goto yy145; if (yych >= ']') goto yy178; ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy145; goto yy175; yy178: ++YYCURSOR; { cur = cursor; yylval.regexp = ranToRE(token()); return RANGE; } yy180: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= '[') { if (yych == '\n') goto yy145; goto yy180; } else { if (yych <= '\\') goto yy201; if (yych <= ']') goto yy202; goto yy180; } yy182: yych = *++YYCURSOR; if (yych == '2') goto yy204; goto yy137; yy183: ++YYCURSOR; yy184: { fatal("illegal closure form, use '{n}', '{n,}', '{n,m}' where n and m are numbers"); } yy185: yych = *++YYCURSOR; if (yych == ',') goto yy205; goto yy187; yy186: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; yy187: if (yybm[0+yych] & 128) { goto yy186; } if (yych == ',') goto yy208; if (yych == '}') goto yy206; goto yy145; yy188: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= '^') { if (yych <= '9') { if (yych <= '/') goto yy145; goto yy188; } else { if (yych <= '@') goto yy145; if (yych <= 'Z') goto yy188; goto yy145; } } else { if (yych <= 'z') { if (yych == '`') goto yy145; goto yy188; } else { if (yych == '}') goto yy209; goto yy145; } } yy190: yych = *++YYCURSOR; if (yych == 'i') goto yy211; goto yy145; yy191: ++YYCURSOR; YYCURSOR -= 2; { RETURN(*tok); } yy193: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yych <= '9') { if (yych <= '\t') { if (yych <= 0x08) goto yy145; goto yy193; } else { if (yych == ' ') goto yy193; goto yy145; } } else { if (yych <= '=') { if (yych <= ':') goto yy195; if (yych <= '<') goto yy145; goto yy196; } else { if (yych == '{') goto yy197; goto yy145; } } yy195: yych = *++YYCURSOR; if (yych == '=') goto yy197; goto yy145; yy196: yych = *++YYCURSOR; if (yych != '>') goto yy145; yy197: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { RETURN(NOCOND); } yy199: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { cur = ptr > tok ? ptr - 1 : cursor; yylval.symbol = Symbol::find(token()); return FFlag ? FID : ID; } yy201: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy145; goto yy180; yy202: ++YYCURSOR; { cur = cursor; yylval.regexp = invToRE(token()); return RANGE; } yy204: yych = *++YYCURSOR; if (yych == 'c') goto yy212; goto yy137; yy205: yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); if (yych <= '/') goto yy184; if (yych <= '9') goto yy213; if (yych == '}') goto yy215; goto yy184; yy206: ++YYCURSOR; { yylval.extop.minsize = atoi((char *)tok+1); yylval.extop.maxsize = atoi((char *)tok+1); RETURN(CLOSESIZE); } yy208: yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); if (yych <= '/') goto yy184; if (yych <= '9') goto yy213; if (yych == '}') goto yy217; goto yy184; yy209: ++YYCURSOR; { if (!FFlag) { fatal("curly braces for names only allowed with -F switch"); } cur = cursor; yylval.symbol = Symbol::find(token(1, cur - tok - 2)); return ID; } yy211: yych = *++YYCURSOR; if (yych == 'n') goto yy219; goto yy145; yy212: yych = *++YYCURSOR; if (yych == ':') goto yy220; goto yy137; yy213: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= '/') goto yy145; if (yych <= '9') goto yy213; if (yych == '}') goto yy221; goto yy145; yy215: ++YYCURSOR; { yylval.op = '*'; RETURN(CLOSE); } yy217: ++YYCURSOR; { yylval.extop.minsize = atoi((char *)tok+1); yylval.extop.maxsize = -1; RETURN(CLOSESIZE); } yy219: yych = *++YYCURSOR; if (yych == 'e') goto yy223; goto yy145; yy220: yych = *++YYCURSOR; if (yych <= '^') { if (yych <= '@') goto yy170; if (yych <= 'Z') goto yy224; goto yy170; } else { if (yych == '`') goto yy170; if (yych <= 'z') goto yy224; goto yy170; } yy221: ++YYCURSOR; { yylval.extop.minsize = atoi((char *)tok+1); yylval.extop.maxsize = MAX(yylval.extop.minsize,atoi(strchr((char *)tok, ',')+1)); RETURN(CLOSESIZE); } yy223: yych = *++YYCURSOR; if (yych <= '0') goto yy228; if (yych <= '9') goto yy145; goto yy228; yy224: yyaccept = 7; YYMARKER = ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yych <= '@') { if (yych <= '9') { if (yych >= '0') goto yy224; } else { if (yych <= ':') goto yy229; if (yych >= '@') goto yy230; } } else { if (yych <= '_') { if (yych <= 'Z') goto yy224; if (yych >= '_') goto yy224; } else { if (yych <= '`') goto yy226; if (yych <= 'z') goto yy224; } } yy226: { cur = cursor; tok += 5; /* skip "re2c:" */ iscfg = 1; yylval.str = new Str(token()); return CONFIG; } yy227: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy228: if (yych <= 0x1F) { if (yych == '\t') goto yy227; goto yy145; } else { if (yych <= ' ') goto yy227; if (yych <= '0') goto yy145; if (yych <= '9') { YYCTXMARKER = YYCURSOR; goto yy231; } goto yy145; } yy229: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= '^') { if (yych <= '@') goto yy145; if (yych <= 'Z') goto yy224; goto yy145; } else { if (yych == '`') goto yy145; if (yych <= 'z') goto yy224; goto yy145; } yy230: yych = *++YYCURSOR; if (yych <= '^') { if (yych <= '@') goto yy145; if (yych <= 'Z') goto yy233; goto yy145; } else { if (yych == '`') goto yy145; if (yych <= 'z') goto yy233; goto yy145; } yy231: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yych <= '\r') { if (yych <= '\t') { if (yych <= 0x08) goto yy145; goto yy235; } else { if (yych <= '\n') goto yy237; if (yych <= '\f') goto yy145; goto yy239; } } else { if (yych <= ' ') { if (yych <= 0x1F) goto yy145; goto yy235; } else { if (yych <= '/') goto yy145; if (yych <= '9') goto yy231; goto yy145; } } yy233: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 'Z') { if (yych <= '/') goto yy226; if (yych <= '9') goto yy233; if (yych <= '@') goto yy226; goto yy233; } else { if (yych <= '_') { if (yych <= '^') goto yy226; goto yy233; } else { if (yych <= '`') goto yy226; if (yych <= 'z') goto yy233; goto yy226; } } yy235: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy235; goto yy145; } else { if (yych <= ' ') goto yy235; if (yych == '"') goto yy240; goto yy145; } yy237: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { set_sourceline(cursor); goto scan; } yy239: yych = *++YYCURSOR; if (yych == '\n') goto yy237; goto yy145; yy240: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3); yych = *YYCURSOR; if (yych <= '!') { if (yych == '\n') goto yy145; goto yy240; } else { if (yych <= '"') goto yy242; if (yych == '\\') goto yy243; goto yy240; } yy242: yych = *++YYCURSOR; if (yych == '\n') goto yy237; if (yych == '\r') goto yy239; goto yy145; yy243: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy145; goto yy240; } code: { YYCTYPE yych; unsigned int yyaccept = 0; static const unsigned char yybm[] = { 96, 96, 96, 96, 96, 96, 96, 96, 96, 112, 0, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 112, 96, 64, 96, 96, 96, 96, 32, 96, 96, 96, 96, 96, 96, 96, 96, 224, 224, 224, 224, 224, 224, 224, 224, 224, 224, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 0, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, }; if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3); yych = *YYCURSOR; if (yych <= '&') { if (yych <= '\n') { if (yych <= 0x00) goto yy246; if (yych <= '\t') goto yy248; goto yy250; } else { if (yych == '"') goto yy252; goto yy248; } } else { if (yych <= '{') { if (yych <= '\'') goto yy253; if (yych <= 'z') goto yy248; goto yy254; } else { if (yych == '}') goto yy256; goto yy248; } } yy246: ++YYCURSOR; { if (cursor == eof) { if (depth) { fatal("missing '}'"); } RETURN(0); } goto code; } yy248: ++YYCURSOR; yy249: { goto code; } yy250: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= '\r') { if (yych <= '\t') { if (yych >= '\t') goto yy258; } else { if (yych <= '\n') goto yy260; if (yych >= '\r') goto yy260; } } else { if (yych <= ' ') { if (yych >= ' ') goto yy258; } else { if (yych == '#') goto yy261; } } yy251: { if (depth == 0) { cur = cursor; tok += strspn(tok, " \t\r\n"); while (cur > tok && strchr(" \t\r\n", cur[-1])) { --cur; } yylval.token = new Token(token(), sourceFileInfo.fname, tline); return CODE; } else if (cursor == eof) { fatal("missing '}'"); } pos = cursor; cline++; goto code; } yy252: yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if (yych == '\n') goto yy249; goto yy265; yy253: yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if (yych == '\n') goto yy249; goto yy268; yy254: ++YYCURSOR; { if (depth == 0) { fatal("Curly braces are not allowed after ':='"); } else { ++depth; } goto code; } yy256: ++YYCURSOR; { if (depth == 0) { fatal("Curly braces are not allowed after ':='"); } else if (--depth == 0) { cur = cursor; yylval.token = new Token(token(), sourceFileInfo.fname, tline); return CODE; } goto code; } yy258: yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 0x1F) { if (yych == '\t') goto yy270; } else { if (yych <= ' ') goto yy270; if (yych == '#') goto yy261; } yy259: YYCURSOR -= 1; { if (depth == 0) { goto code; } else if (cursor == eof) { fatal("missing '}'"); } pos = cursor; cline++; goto code; } yy260: ++YYCURSOR; goto yy259; yy261: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; if (yybm[0+yych] & 16) { goto yy261; } if (yych == 'l') goto yy272; yy263: YYCURSOR = YYMARKER; if (yyaccept <= 1) { if (yyaccept == 0) { goto yy251; } else { goto yy249; } } else { goto yy259; } yy264: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy265: if (yybm[0+yych] & 32) { goto yy264; } if (yych <= '\n') goto yy263; if (yych <= '"') goto yy248; ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy263; goto yy264; yy267: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy268: if (yybm[0+yych] & 64) { goto yy267; } if (yych <= '\n') goto yy263; if (yych <= '\'') goto yy248; ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy263; goto yy267; yy270: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy270; goto yy263; } else { if (yych <= ' ') goto yy270; if (yych == '#') goto yy261; goto yy263; } yy272: yych = *++YYCURSOR; if (yych != 'i') goto yy263; yych = *++YYCURSOR; if (yych != 'n') goto yy263; yych = *++YYCURSOR; if (yych != 'e') goto yy263; yych = *++YYCURSOR; if (yych <= '0') goto yy277; if (yych <= '9') goto yy263; goto yy277; yy276: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy277: if (yych <= 0x1F) { if (yych == '\t') goto yy276; goto yy263; } else { if (yych <= ' ') goto yy276; if (yych <= '0') goto yy263; if (yych >= ':') goto yy263; YYCTXMARKER = YYCURSOR; } yy278: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yybm[0+yych] & 128) { goto yy278; } if (yych <= '\f') { if (yych <= 0x08) goto yy263; if (yych <= '\t') goto yy280; if (yych <= '\n') goto yy282; goto yy263; } else { if (yych <= '\r') goto yy284; if (yych != ' ') goto yy263; } yy280: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy280; goto yy263; } else { if (yych <= ' ') goto yy280; if (yych == '"') goto yy285; goto yy263; } yy282: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { set_sourceline(cursor); goto code; } yy284: yych = *++YYCURSOR; if (yych == '\n') goto yy282; goto yy263; yy285: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3); yych = *YYCURSOR; if (yych <= '!') { if (yych == '\n') goto yy263; goto yy285; } else { if (yych <= '"') goto yy287; if (yych == '\\') goto yy288; goto yy285; } yy287: yych = *++YYCURSOR; if (yych == '\n') goto yy282; if (yych == '\r') goto yy284; goto yy263; yy288: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy263; goto yy285; } comment: { YYCTYPE yych; static const unsigned char yybm[] = { 128, 128, 128, 128, 128, 128, 128, 128, 128, 160, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 160, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yych <= ')') { if (yych == '\n') goto yy293; } else { if (yych <= '*') goto yy295; if (yych == '/') goto yy296; } ++YYCURSOR; yy292: { if (cursor == eof) { RETURN(0); } goto comment; } yy293: yych = *(YYMARKER = ++YYCURSOR); if (yybm[0+yych] & 32) { goto yy297; } if (yych == '#') goto yy300; yy294: { if (cursor == eof) { RETURN(0); } tok = pos = cursor; cline++; goto comment; } yy295: yych = *++YYCURSOR; if (yych == '/') goto yy302; goto yy292; yy296: yych = *++YYCURSOR; if (yych == '*') goto yy304; goto yy292; yy297: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 32) { goto yy297; } if (yych == '#') goto yy300; yy299: YYCURSOR = YYMARKER; goto yy294; yy300: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy300; goto yy299; } else { if (yych <= ' ') goto yy300; if (yych == 'l') goto yy306; goto yy299; } yy302: ++YYCURSOR; { if (--depth == 0) { goto scan; } else { goto comment; } } yy304: ++YYCURSOR; { ++depth; fatal("ambiguous /* found"); goto comment; } yy306: yych = *++YYCURSOR; if (yych != 'i') goto yy299; yych = *++YYCURSOR; if (yych != 'n') goto yy299; yych = *++YYCURSOR; if (yych != 'e') goto yy299; yych = *++YYCURSOR; if (yych <= '0') goto yy311; if (yych <= '9') goto yy299; goto yy311; yy310: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy311: if (yych <= 0x1F) { if (yych == '\t') goto yy310; goto yy299; } else { if (yych <= ' ') goto yy310; if (yych <= '0') goto yy299; if (yych >= ':') goto yy299; YYCTXMARKER = YYCURSOR; } yy312: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yybm[0+yych] & 64) { goto yy312; } if (yych <= '\f') { if (yych <= 0x08) goto yy299; if (yych <= '\t') goto yy314; if (yych <= '\n') goto yy316; goto yy299; } else { if (yych <= '\r') goto yy318; if (yych != ' ') goto yy299; } yy314: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= 0x1F) { if (yych == '\t') goto yy314; goto yy299; } else { if (yych <= ' ') goto yy314; if (yych == '"') goto yy319; goto yy299; } yy316: ++YYCURSOR; YYCURSOR = YYCTXMARKER; { set_sourceline(cursor); goto comment; } yy318: yych = *++YYCURSOR; if (yych == '\n') goto yy316; goto yy299; yy319: ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3); yych = *YYCURSOR; if (yybm[0+yych] & 128) { goto yy319; } if (yych <= '\n') goto yy299; if (yych >= '#') goto yy322; yych = *++YYCURSOR; if (yych == '\n') goto yy316; if (yych == '\r') goto yy318; goto yy299; yy322: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy299; goto yy319; } nextLine: { YYCTYPE yych; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy327; ++YYCURSOR; { if(cursor == eof) { RETURN(0); } goto nextLine; } yy327: ++YYCURSOR; { if(cursor == eof) { RETURN(0); } tok = pos = cursor; cline++; goto scan; } } config: { YYCTYPE yych; static const unsigned char yybm[] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, }; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 128) { goto yy333; } if (yych == '=') goto yy336; ++YYCURSOR; { fatal("missing '='"); } yy333: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 128) { goto yy333; } { goto config; } yy336: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\t') goto yy336; if (yych == ' ') goto yy336; { iscfg = 2; cur = cursor; RETURN('='); } } value: { YYCTYPE yych; static const unsigned char yybm[] = { 220, 220, 220, 220, 220, 220, 220, 220, 220, 192, 0, 220, 220, 192, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 192, 220, 148, 220, 220, 220, 220, 76, 220, 220, 220, 220, 220, 220, 220, 220, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 220, 192, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, }; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yych <= '&') { if (yych <= '\r') { if (yych <= 0x08) goto yy342; if (yych <= '\n') goto yy341; if (yych <= '\f') goto yy342; } else { if (yych <= ' ') { if (yych <= 0x1F) goto yy342; } else { if (yych == '"') goto yy344; goto yy342; } } } else { if (yych <= '/') { if (yych <= '\'') goto yy346; if (yych == '-') goto yy348; goto yy342; } else { if (yych <= '9') { if (yych <= '0') goto yy349; goto yy351; } else { if (yych != ';') goto yy342; } } } yy341: { cur = cursor; yylval.str = new Str(token()); iscfg = 0; return VALUE; } yy342: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy343: if (yybm[0+yych] & 4) { goto yy342; } goto yy341; yy344: YYMARKER = ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 8) { goto yy344; } if (yych <= ' ') { if (yych == '\n') goto yy341; goto yy353; } else { if (yych <= '"') goto yy342; if (yych <= ';') goto yy353; goto yy356; } yy346: YYMARKER = ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 16) { goto yy346; } if (yych <= ' ') { if (yych == '\n') goto yy341; goto yy357; } else { if (yych <= '\'') goto yy342; if (yych <= ';') goto yy357; goto yy359; } yy348: yych = *++YYCURSOR; if (yych <= '0') goto yy343; if (yych <= '9') goto yy351; goto yy343; yy349: yych = *++YYCURSOR; if (yybm[0+yych] & 4) { goto yy342; } yy350: { cur = cursor; yylval.number = atoi(token().to_string().c_str()); iscfg = 0; return NUMBER; } yy351: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 32) { goto yy351; } if (yych <= '\r') { if (yych <= 0x08) goto yy342; if (yych <= '\n') goto yy350; if (yych <= '\f') goto yy342; goto yy350; } else { if (yych <= ' ') { if (yych <= 0x1F) goto yy342; goto yy350; } else { if (yych == ';') goto yy350; goto yy342; } } yy353: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 64) { goto yy353; } if (yych <= '\n') goto yy355; if (yych <= '"') goto yy360; goto yy361; yy355: YYCURSOR = YYMARKER; goto yy341; yy356: YYMARKER = ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= '\r') { if (yych <= '\t') { if (yych <= 0x08) goto yy344; goto yy353; } else { if (yych <= '\n') goto yy341; if (yych <= '\f') goto yy344; goto yy353; } } else { if (yych <= ' ') { if (yych <= 0x1F) goto yy344; goto yy353; } else { if (yych == ';') goto yy353; goto yy344; } } yy357: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 128) { goto yy357; } if (yych <= '\n') goto yy355; if (yych <= '\'') goto yy360; goto yy362; yy359: YYMARKER = ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych <= '\r') { if (yych <= '\t') { if (yych <= 0x08) goto yy346; goto yy357; } else { if (yych <= '\n') goto yy341; if (yych <= '\f') goto yy346; goto yy357; } } else { if (yych <= ' ') { if (yych <= 0x1F) goto yy346; goto yy357; } else { if (yych == ';') goto yy357; goto yy346; } } yy360: ++YYCURSOR; goto yy341; yy361: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy355; goto yy353; yy362: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy355; goto yy357; } } void Scanner::set_sourceline(char *& cursor) { sourceline: tok = cursor; { YYCTYPE yych; static const unsigned char yybm[] = { 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; if (yych <= '!') { if (yych == '\n') goto yy367; } else { if (yych <= '"') goto yy369; if (yych <= '0') goto yy365; if (yych <= '9') goto yy370; } yy365: ++YYCURSOR; yy366: { goto sourceline; } yy367: ++YYCURSOR; { if (cursor == eof) { --cursor; } else { pos = cursor; } tok = cursor; return; } yy369: yych = *(YYMARKER = ++YYCURSOR); if (yych == '\n') goto yy366; goto yy374; yy370: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yybm[0+yych] & 64) { goto yy370; } { cur = cursor; cline = atoi(token().to_string().c_str()); goto sourceline; } yy373: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy374: if (yybm[0+yych] & 128) { goto yy373; } if (yych <= '\n') goto yy375; if (yych <= '"') goto yy376; goto yy378; yy375: YYCURSOR = YYMARKER; goto yy366; yy376: ++YYCURSOR; { cur = cursor; sourceFileInfo.set_fname(token(1, cur - tok - 2).to_string()); goto sourceline; } yy378: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; if (yych == '\n') goto yy375; goto yy373; } } } // end namespace re2c re2c: warning: line 608: rule matches empty string [-Wmatch-empty-string]