From be9368d872e5c318d3a2cb489a155801e35fb4b2 Mon Sep 17 00:00:00 2001 From: Peter Johnson Date: Mon, 10 Oct 2005 05:11:46 +0000 Subject: [PATCH] re2c: Unbreak distcheck. svn path=/trunk/yasm/; revision=1277 --- tools/re2c/Makefile.inc | 1 - tools/re2c/bootstrap/scanner.c | 157 ++++++++++++++++----------------- tools/re2c/scanner.c | 157 ++++++++++++++++----------------- tools/re2c/scanner.re | 1 - 4 files changed, 156 insertions(+), 160 deletions(-) diff --git a/tools/re2c/Makefile.inc b/tools/re2c/Makefile.inc index 5efc4d7c..06f47134 100644 --- a/tools/re2c/Makefile.inc +++ b/tools/re2c/Makefile.inc @@ -103,7 +103,6 @@ EXTRA_DIST += tools/re2c/NO_WARRANTY EXTRA_DIST += tools/re2c/README EXTRA_DIST += tools/re2c/scanner.re EXTRA_DIST += tools/re2c/re2c.1 -EXTRA_DIST += tools/re2c/bootstrap/re2c.man EXTRA_DIST += tools/re2c/bootstrap/scanner.c EXTRA_DIST += tools/re2c/doc/loplas.ps.gz EXTRA_DIST += tools/re2c/doc/sample.bib diff --git a/tools/re2c/bootstrap/scanner.c b/tools/re2c/bootstrap/scanner.c index 2bfbeb3d..fd0ca93e 100644 --- a/tools/re2c/bootstrap/scanner.c +++ b/tools/re2c/bootstrap/scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.9.1-C on Sun Oct 9 15:00:35 2005 +/* Generated by re2c 0.9.1-C on Sun Oct 9 22:15:58 2005 */ #line 1 "scanner.re" #include @@ -7,7 +7,6 @@ #include "tools/re2c/parse.h" #include "tools/re2c/globals.h" #include "re2c-parser.h" -#include "globals.h" #ifndef MAX #define MAX(a,b) (((a)>(b))?(a):(b)) @@ -69,7 +68,7 @@ fill(Scanner *s, unsigned char *cursor) return cursor; } -#line 80 "scanner.re" +#line 79 "scanner.re" int @@ -85,7 +84,7 @@ Scanner_echo(Scanner *s, FILE *out) s->tok = cursor; echo: -#line 88 "scanner.c" +#line 87 "scanner.c" { YYCTYPE yych; unsigned int yyaccept; @@ -108,33 +107,33 @@ yy2: yyaccept = 0; if(yych == '*') goto yy12; goto yy3; yy3: -#line 118 "scanner.re" +#line 117 "scanner.re" { goto echo; } -#line 113 "scanner.c" +#line 112 "scanner.c" yy4: yych = *++YYCURSOR; if(yych == '/') goto yy10; goto yy3; yy5: yych = *++YYCURSOR; goto yy6; yy6: -#line 113 "scanner.re" +#line 112 "scanner.re" { fwrite(s->tok, 1, cursor - s->tok, out); s->tok = s->pos = cursor; s->cline++; oline++; goto echo; } -#line 124 "scanner.c" +#line 123 "scanner.c" yy7: yych = *++YYCURSOR; goto yy8; yy8: -#line 116 "scanner.re" +#line 115 "scanner.re" { fwrite(s->tok, 1, cursor - s->tok - 1, out); /* -1 so we don't write out the \0 */ if(cursor == s->eof) { RETURN(0); } } -#line 131 "scanner.c" +#line 130 "scanner.c" yy9: yych = *++YYCURSOR; goto yy3; yy10: yych = *++YYCURSOR; goto yy11; yy11: -#line 104 "scanner.re" +#line 103 "scanner.re" { if (ignore_eoc) { ignore_eoc = 0; @@ -144,7 +143,7 @@ yy11: s->tok = s->pos = cursor; goto echo; } -#line 147 "scanner.c" +#line 146 "scanner.c" yy12: yych = *++YYCURSOR; if(yych == '!') goto yy14; goto yy13; @@ -171,11 +170,11 @@ yy18: yych = *++YYCURSOR; yy19: yych = *++YYCURSOR; goto yy20; yy20: -#line 95 "scanner.re" +#line 94 "scanner.re" { fwrite(s->tok, 1, &cursor[-7] - s->tok, out); s->tok = cursor; RETURN(1); } -#line 178 "scanner.c" +#line 177 "scanner.c" yy21: yych = *++YYCURSOR; if(yych != 'x') goto yy13; goto yy22; @@ -197,16 +196,16 @@ yy26: yych = *++YYCURSOR; yy27: yych = *++YYCURSOR; goto yy28; yy28: -#line 98 "scanner.re" +#line 97 "scanner.re" { fprintf(out, "#define YYMAXFILL %u\n", maxFill); s->tok = s->pos = cursor; ignore_eoc = 1; goto echo; } -#line 207 "scanner.c" +#line 206 "scanner.c" } -#line 119 "scanner.re" +#line 118 "scanner.re" } @@ -222,7 +221,7 @@ scan: s->tline = s->cline; s->tok = cursor; -#line 225 "scanner.c" +#line 224 "scanner.c" { YYCTYPE yych; unsigned int yyaccept; @@ -285,51 +284,51 @@ yy31: yyaccept = 0; if(yych <= '9') goto yy84; goto yy32; yy32: -#line 134 "scanner.re" +#line 133 "scanner.re" { depth = 1; goto code; } -#line 292 "scanner.c" +#line 291 "scanner.c" yy33: yych = *++YYCURSOR; if(yych == '*') goto yy82; goto yy34; yy34: -#line 164 "scanner.re" +#line 163 "scanner.re" { RETURN(*s->tok); } -#line 299 "scanner.c" +#line 298 "scanner.c" yy35: yych = *++YYCURSOR; if(yych == '/') goto yy80; goto yy36; yy36: -#line 166 "scanner.re" +#line 165 "scanner.re" { yylval.op = *s->tok; RETURN(CLOSE); } -#line 307 "scanner.c" +#line 306 "scanner.c" yy37: yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if(yych != '\n') goto yy76; goto yy38; yy38: -#line 151 "scanner.re" +#line 150 "scanner.re" { Scanner_fatal(s, "unterminated string constant (missing \")"); } -#line 315 "scanner.c" +#line 314 "scanner.c" yy39: yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); if(yych != '\n') goto yy71; goto yy40; yy40: -#line 152 "scanner.re" +#line 151 "scanner.re" { Scanner_fatal(s, "unterminated string constant (missing ')"); } -#line 323 "scanner.c" +#line 322 "scanner.c" yy41: yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); if(yych == '\n') goto yy42; if(yych == '^') goto yy62; goto yy60; yy42: -#line 162 "scanner.re" +#line 161 "scanner.re" { Scanner_fatal(s, "unterminated range (missing ])"); } -#line 332 "scanner.c" +#line 331 "scanner.c" yy43: yych = *++YYCURSOR; goto yy34; yy44: yych = *++YYCURSOR; @@ -337,45 +336,45 @@ yy44: yych = *++YYCURSOR; yy45: yych = *++YYCURSOR; goto yy58; yy46: -#line 181 "scanner.re" +#line 180 "scanner.re" { SubStr substr; s->cur = cursor; substr = Scanner_token(s); yylval.symbol = Symbol_find(&substr); return ID; } -#line 346 "scanner.c" +#line 345 "scanner.c" yy47: yych = *++YYCURSOR; goto yy56; yy48: -#line 187 "scanner.re" +#line 186 "scanner.re" { goto scan; } -#line 352 "scanner.c" +#line 351 "scanner.c" yy49: yych = *++YYCURSOR; goto yy50; yy50: -#line 189 "scanner.re" +#line 188 "scanner.re" { if(cursor == s->eof) RETURN(0); s->pos = cursor; s->cline++; goto scan; } -#line 361 "scanner.c" +#line 360 "scanner.c" yy51: yych = *++YYCURSOR; goto yy52; yy52: -#line 194 "scanner.re" +#line 193 "scanner.re" { s->cur = cursor; yylval.regexp = mkDot(); return RANGE; } -#line 370 "scanner.c" +#line 369 "scanner.c" yy53: yych = *++YYCURSOR; goto yy54; yy54: -#line 199 "scanner.re" +#line 198 "scanner.re" { fprintf(stderr, "unexpected character: '%c'\n", *s->tok); goto scan; } -#line 378 "scanner.c" +#line 377 "scanner.c" yy55: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -436,11 +435,11 @@ yy64: ++YYCURSOR; yy65: yych = *++YYCURSOR; goto yy66; yy66: -#line 158 "scanner.re" +#line 157 "scanner.re" { s->cur = cursor; yylval.regexp = ranToRE(Scanner_token(s)); return RANGE; } -#line 443 "scanner.c" +#line 442 "scanner.c" yy67: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -449,11 +448,11 @@ yy67: ++YYCURSOR; yy68: yych = *++YYCURSOR; goto yy69; yy69: -#line 154 "scanner.re" +#line 153 "scanner.re" { s->cur = cursor; yylval.regexp = invToRE(Scanner_token(s)); return RANGE; } -#line 456 "scanner.c" +#line 455 "scanner.c" yy70: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -474,11 +473,11 @@ yy72: ++YYCURSOR; yy73: yych = *++YYCURSOR; goto yy74; yy74: -#line 147 "scanner.re" +#line 146 "scanner.re" { s->cur = cursor; yylval.regexp = strToCaseInsensitiveRE(Scanner_token(s)); return STRING; } -#line 481 "scanner.c" +#line 480 "scanner.c" yy75: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -499,25 +498,25 @@ yy77: ++YYCURSOR; yy78: yych = *++YYCURSOR; goto yy79; yy79: -#line 143 "scanner.re" +#line 142 "scanner.re" { s->cur = cursor; yylval.regexp = strToRE(Scanner_token(s)); return STRING; } -#line 506 "scanner.c" +#line 505 "scanner.c" yy80: yych = *++YYCURSOR; goto yy81; yy81: -#line 140 "scanner.re" +#line 139 "scanner.re" { s->tok = cursor; RETURN(0); } -#line 513 "scanner.c" +#line 512 "scanner.c" yy82: yych = *++YYCURSOR; goto yy83; yy83: -#line 137 "scanner.re" +#line 136 "scanner.re" { depth = 1; goto comment; } -#line 520 "scanner.c" +#line 519 "scanner.c" yy84: ++YYCURSOR; if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; @@ -533,22 +532,22 @@ yy85: if(yych <= '/'){ yy86: yych = *++YYCURSOR; goto yy87; yy87: -#line 169 "scanner.re" +#line 168 "scanner.re" { yylval.extop.minsize = atoi((char *)s->tok+1); yylval.extop.maxsize = atoi((char *)s->tok+1); RETURN(CLOSESIZE); } -#line 540 "scanner.c" +#line 539 "scanner.c" yy88: yych = *++YYCURSOR; if(yych != '}') goto yy92; goto yy89; yy89: yych = *++YYCURSOR; goto yy90; yy90: -#line 177 "scanner.re" +#line 176 "scanner.re" { yylval.extop.minsize = atoi((char *)s->tok+1); yylval.extop.maxsize = -1; RETURN(CLOSESIZE); } -#line 551 "scanner.c" +#line 550 "scanner.c" yy91: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -560,18 +559,18 @@ yy92: if(yych <= '/') goto yy61; yy93: yych = *++YYCURSOR; goto yy94; yy94: -#line 173 "scanner.re" +#line 172 "scanner.re" { yylval.extop.minsize = atoi((char *)s->tok+1); yylval.extop.maxsize = MAX(yylval.extop.minsize,atoi(strchr((char *)s->tok, ',')+1)); RETURN(CLOSESIZE); } -#line 567 "scanner.c" +#line 566 "scanner.c" } -#line 202 "scanner.re" +#line 201 "scanner.re" code: -#line 574 "scanner.c" +#line 573 "scanner.c" { YYCTYPE yych; unsigned int yyaccept; @@ -601,36 +600,36 @@ yy95: yy97: yych = *++YYCURSOR; goto yy98; yy98: -#line 206 "scanner.re" +#line 205 "scanner.re" { if(--depth == 0){ s->cur = cursor; yylval.token = Token_new(Scanner_token(s), s->tline); return CODE; } goto code; } -#line 611 "scanner.c" +#line 610 "scanner.c" yy99: yych = *++YYCURSOR; goto yy100; yy100: -#line 212 "scanner.re" +#line 211 "scanner.re" { ++depth; goto code; } -#line 618 "scanner.c" +#line 617 "scanner.c" yy101: yych = *++YYCURSOR; goto yy102; yy102: -#line 214 "scanner.re" +#line 213 "scanner.re" { if(cursor == s->eof) Scanner_fatal(s, "missing '}'"); s->pos = cursor; s->cline++; goto code; } -#line 627 "scanner.c" +#line 626 "scanner.c" yy103: yych = *++YYCURSOR; goto yy104; yy104: -#line 218 "scanner.re" +#line 217 "scanner.re" { goto code; } -#line 633 "scanner.c" +#line 632 "scanner.c" yy105: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if(yych == '\n') goto yy104; @@ -678,12 +677,12 @@ yy113: ++YYCURSOR; if(yych == '\n') goto yy109; goto yy111; } -#line 219 "scanner.re" +#line 218 "scanner.re" comment: -#line 686 "scanner.c" +#line 685 "scanner.c" { YYCTYPE yych; goto yy114; @@ -703,41 +702,41 @@ yy116: yych = *++YYCURSOR; if(yych == '/') goto yy124; goto yy117; yy117: -#line 233 "scanner.re" +#line 232 "scanner.re" { goto comment; } -#line 708 "scanner.c" +#line 707 "scanner.c" yy118: yych = *++YYCURSOR; if(yych == '*') goto yy122; goto yy117; yy119: yych = *++YYCURSOR; goto yy120; yy120: -#line 229 "scanner.re" +#line 228 "scanner.re" { if(cursor == s->eof) RETURN(0); s->tok = s->pos = cursor; s->cline++; goto comment; } -#line 720 "scanner.c" +#line 719 "scanner.c" yy121: yych = *++YYCURSOR; goto yy117; yy122: yych = *++YYCURSOR; goto yy123; yy123: -#line 227 "scanner.re" +#line 226 "scanner.re" { ++depth; goto comment; } -#line 729 "scanner.c" +#line 728 "scanner.c" yy124: yych = *++YYCURSOR; goto yy125; yy125: -#line 223 "scanner.re" +#line 222 "scanner.re" { if(--depth == 0) goto scan; else goto comment; } -#line 738 "scanner.c" +#line 737 "scanner.c" } -#line 234 "scanner.re" +#line 233 "scanner.re" } diff --git a/tools/re2c/scanner.c b/tools/re2c/scanner.c index 2bfbeb3d..fd0ca93e 100644 --- a/tools/re2c/scanner.c +++ b/tools/re2c/scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.9.1-C on Sun Oct 9 15:00:35 2005 +/* Generated by re2c 0.9.1-C on Sun Oct 9 22:15:58 2005 */ #line 1 "scanner.re" #include @@ -7,7 +7,6 @@ #include "tools/re2c/parse.h" #include "tools/re2c/globals.h" #include "re2c-parser.h" -#include "globals.h" #ifndef MAX #define MAX(a,b) (((a)>(b))?(a):(b)) @@ -69,7 +68,7 @@ fill(Scanner *s, unsigned char *cursor) return cursor; } -#line 80 "scanner.re" +#line 79 "scanner.re" int @@ -85,7 +84,7 @@ Scanner_echo(Scanner *s, FILE *out) s->tok = cursor; echo: -#line 88 "scanner.c" +#line 87 "scanner.c" { YYCTYPE yych; unsigned int yyaccept; @@ -108,33 +107,33 @@ yy2: yyaccept = 0; if(yych == '*') goto yy12; goto yy3; yy3: -#line 118 "scanner.re" +#line 117 "scanner.re" { goto echo; } -#line 113 "scanner.c" +#line 112 "scanner.c" yy4: yych = *++YYCURSOR; if(yych == '/') goto yy10; goto yy3; yy5: yych = *++YYCURSOR; goto yy6; yy6: -#line 113 "scanner.re" +#line 112 "scanner.re" { fwrite(s->tok, 1, cursor - s->tok, out); s->tok = s->pos = cursor; s->cline++; oline++; goto echo; } -#line 124 "scanner.c" +#line 123 "scanner.c" yy7: yych = *++YYCURSOR; goto yy8; yy8: -#line 116 "scanner.re" +#line 115 "scanner.re" { fwrite(s->tok, 1, cursor - s->tok - 1, out); /* -1 so we don't write out the \0 */ if(cursor == s->eof) { RETURN(0); } } -#line 131 "scanner.c" +#line 130 "scanner.c" yy9: yych = *++YYCURSOR; goto yy3; yy10: yych = *++YYCURSOR; goto yy11; yy11: -#line 104 "scanner.re" +#line 103 "scanner.re" { if (ignore_eoc) { ignore_eoc = 0; @@ -144,7 +143,7 @@ yy11: s->tok = s->pos = cursor; goto echo; } -#line 147 "scanner.c" +#line 146 "scanner.c" yy12: yych = *++YYCURSOR; if(yych == '!') goto yy14; goto yy13; @@ -171,11 +170,11 @@ yy18: yych = *++YYCURSOR; yy19: yych = *++YYCURSOR; goto yy20; yy20: -#line 95 "scanner.re" +#line 94 "scanner.re" { fwrite(s->tok, 1, &cursor[-7] - s->tok, out); s->tok = cursor; RETURN(1); } -#line 178 "scanner.c" +#line 177 "scanner.c" yy21: yych = *++YYCURSOR; if(yych != 'x') goto yy13; goto yy22; @@ -197,16 +196,16 @@ yy26: yych = *++YYCURSOR; yy27: yych = *++YYCURSOR; goto yy28; yy28: -#line 98 "scanner.re" +#line 97 "scanner.re" { fprintf(out, "#define YYMAXFILL %u\n", maxFill); s->tok = s->pos = cursor; ignore_eoc = 1; goto echo; } -#line 207 "scanner.c" +#line 206 "scanner.c" } -#line 119 "scanner.re" +#line 118 "scanner.re" } @@ -222,7 +221,7 @@ scan: s->tline = s->cline; s->tok = cursor; -#line 225 "scanner.c" +#line 224 "scanner.c" { YYCTYPE yych; unsigned int yyaccept; @@ -285,51 +284,51 @@ yy31: yyaccept = 0; if(yych <= '9') goto yy84; goto yy32; yy32: -#line 134 "scanner.re" +#line 133 "scanner.re" { depth = 1; goto code; } -#line 292 "scanner.c" +#line 291 "scanner.c" yy33: yych = *++YYCURSOR; if(yych == '*') goto yy82; goto yy34; yy34: -#line 164 "scanner.re" +#line 163 "scanner.re" { RETURN(*s->tok); } -#line 299 "scanner.c" +#line 298 "scanner.c" yy35: yych = *++YYCURSOR; if(yych == '/') goto yy80; goto yy36; yy36: -#line 166 "scanner.re" +#line 165 "scanner.re" { yylval.op = *s->tok; RETURN(CLOSE); } -#line 307 "scanner.c" +#line 306 "scanner.c" yy37: yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if(yych != '\n') goto yy76; goto yy38; yy38: -#line 151 "scanner.re" +#line 150 "scanner.re" { Scanner_fatal(s, "unterminated string constant (missing \")"); } -#line 315 "scanner.c" +#line 314 "scanner.c" yy39: yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); if(yych != '\n') goto yy71; goto yy40; yy40: -#line 152 "scanner.re" +#line 151 "scanner.re" { Scanner_fatal(s, "unterminated string constant (missing ')"); } -#line 323 "scanner.c" +#line 322 "scanner.c" yy41: yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); if(yych == '\n') goto yy42; if(yych == '^') goto yy62; goto yy60; yy42: -#line 162 "scanner.re" +#line 161 "scanner.re" { Scanner_fatal(s, "unterminated range (missing ])"); } -#line 332 "scanner.c" +#line 331 "scanner.c" yy43: yych = *++YYCURSOR; goto yy34; yy44: yych = *++YYCURSOR; @@ -337,45 +336,45 @@ yy44: yych = *++YYCURSOR; yy45: yych = *++YYCURSOR; goto yy58; yy46: -#line 181 "scanner.re" +#line 180 "scanner.re" { SubStr substr; s->cur = cursor; substr = Scanner_token(s); yylval.symbol = Symbol_find(&substr); return ID; } -#line 346 "scanner.c" +#line 345 "scanner.c" yy47: yych = *++YYCURSOR; goto yy56; yy48: -#line 187 "scanner.re" +#line 186 "scanner.re" { goto scan; } -#line 352 "scanner.c" +#line 351 "scanner.c" yy49: yych = *++YYCURSOR; goto yy50; yy50: -#line 189 "scanner.re" +#line 188 "scanner.re" { if(cursor == s->eof) RETURN(0); s->pos = cursor; s->cline++; goto scan; } -#line 361 "scanner.c" +#line 360 "scanner.c" yy51: yych = *++YYCURSOR; goto yy52; yy52: -#line 194 "scanner.re" +#line 193 "scanner.re" { s->cur = cursor; yylval.regexp = mkDot(); return RANGE; } -#line 370 "scanner.c" +#line 369 "scanner.c" yy53: yych = *++YYCURSOR; goto yy54; yy54: -#line 199 "scanner.re" +#line 198 "scanner.re" { fprintf(stderr, "unexpected character: '%c'\n", *s->tok); goto scan; } -#line 378 "scanner.c" +#line 377 "scanner.c" yy55: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -436,11 +435,11 @@ yy64: ++YYCURSOR; yy65: yych = *++YYCURSOR; goto yy66; yy66: -#line 158 "scanner.re" +#line 157 "scanner.re" { s->cur = cursor; yylval.regexp = ranToRE(Scanner_token(s)); return RANGE; } -#line 443 "scanner.c" +#line 442 "scanner.c" yy67: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -449,11 +448,11 @@ yy67: ++YYCURSOR; yy68: yych = *++YYCURSOR; goto yy69; yy69: -#line 154 "scanner.re" +#line 153 "scanner.re" { s->cur = cursor; yylval.regexp = invToRE(Scanner_token(s)); return RANGE; } -#line 456 "scanner.c" +#line 455 "scanner.c" yy70: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -474,11 +473,11 @@ yy72: ++YYCURSOR; yy73: yych = *++YYCURSOR; goto yy74; yy74: -#line 147 "scanner.re" +#line 146 "scanner.re" { s->cur = cursor; yylval.regexp = strToCaseInsensitiveRE(Scanner_token(s)); return STRING; } -#line 481 "scanner.c" +#line 480 "scanner.c" yy75: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -499,25 +498,25 @@ yy77: ++YYCURSOR; yy78: yych = *++YYCURSOR; goto yy79; yy79: -#line 143 "scanner.re" +#line 142 "scanner.re" { s->cur = cursor; yylval.regexp = strToRE(Scanner_token(s)); return STRING; } -#line 506 "scanner.c" +#line 505 "scanner.c" yy80: yych = *++YYCURSOR; goto yy81; yy81: -#line 140 "scanner.re" +#line 139 "scanner.re" { s->tok = cursor; RETURN(0); } -#line 513 "scanner.c" +#line 512 "scanner.c" yy82: yych = *++YYCURSOR; goto yy83; yy83: -#line 137 "scanner.re" +#line 136 "scanner.re" { depth = 1; goto comment; } -#line 520 "scanner.c" +#line 519 "scanner.c" yy84: ++YYCURSOR; if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; @@ -533,22 +532,22 @@ yy85: if(yych <= '/'){ yy86: yych = *++YYCURSOR; goto yy87; yy87: -#line 169 "scanner.re" +#line 168 "scanner.re" { yylval.extop.minsize = atoi((char *)s->tok+1); yylval.extop.maxsize = atoi((char *)s->tok+1); RETURN(CLOSESIZE); } -#line 540 "scanner.c" +#line 539 "scanner.c" yy88: yych = *++YYCURSOR; if(yych != '}') goto yy92; goto yy89; yy89: yych = *++YYCURSOR; goto yy90; yy90: -#line 177 "scanner.re" +#line 176 "scanner.re" { yylval.extop.minsize = atoi((char *)s->tok+1); yylval.extop.maxsize = -1; RETURN(CLOSESIZE); } -#line 551 "scanner.c" +#line 550 "scanner.c" yy91: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -560,18 +559,18 @@ yy92: if(yych <= '/') goto yy61; yy93: yych = *++YYCURSOR; goto yy94; yy94: -#line 173 "scanner.re" +#line 172 "scanner.re" { yylval.extop.minsize = atoi((char *)s->tok+1); yylval.extop.maxsize = MAX(yylval.extop.minsize,atoi(strchr((char *)s->tok, ',')+1)); RETURN(CLOSESIZE); } -#line 567 "scanner.c" +#line 566 "scanner.c" } -#line 202 "scanner.re" +#line 201 "scanner.re" code: -#line 574 "scanner.c" +#line 573 "scanner.c" { YYCTYPE yych; unsigned int yyaccept; @@ -601,36 +600,36 @@ yy95: yy97: yych = *++YYCURSOR; goto yy98; yy98: -#line 206 "scanner.re" +#line 205 "scanner.re" { if(--depth == 0){ s->cur = cursor; yylval.token = Token_new(Scanner_token(s), s->tline); return CODE; } goto code; } -#line 611 "scanner.c" +#line 610 "scanner.c" yy99: yych = *++YYCURSOR; goto yy100; yy100: -#line 212 "scanner.re" +#line 211 "scanner.re" { ++depth; goto code; } -#line 618 "scanner.c" +#line 617 "scanner.c" yy101: yych = *++YYCURSOR; goto yy102; yy102: -#line 214 "scanner.re" +#line 213 "scanner.re" { if(cursor == s->eof) Scanner_fatal(s, "missing '}'"); s->pos = cursor; s->cline++; goto code; } -#line 627 "scanner.c" +#line 626 "scanner.c" yy103: yych = *++YYCURSOR; goto yy104; yy104: -#line 218 "scanner.re" +#line 217 "scanner.re" { goto code; } -#line 633 "scanner.c" +#line 632 "scanner.c" yy105: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if(yych == '\n') goto yy104; @@ -678,12 +677,12 @@ yy113: ++YYCURSOR; if(yych == '\n') goto yy109; goto yy111; } -#line 219 "scanner.re" +#line 218 "scanner.re" comment: -#line 686 "scanner.c" +#line 685 "scanner.c" { YYCTYPE yych; goto yy114; @@ -703,41 +702,41 @@ yy116: yych = *++YYCURSOR; if(yych == '/') goto yy124; goto yy117; yy117: -#line 233 "scanner.re" +#line 232 "scanner.re" { goto comment; } -#line 708 "scanner.c" +#line 707 "scanner.c" yy118: yych = *++YYCURSOR; if(yych == '*') goto yy122; goto yy117; yy119: yych = *++YYCURSOR; goto yy120; yy120: -#line 229 "scanner.re" +#line 228 "scanner.re" { if(cursor == s->eof) RETURN(0); s->tok = s->pos = cursor; s->cline++; goto comment; } -#line 720 "scanner.c" +#line 719 "scanner.c" yy121: yych = *++YYCURSOR; goto yy117; yy122: yych = *++YYCURSOR; goto yy123; yy123: -#line 227 "scanner.re" +#line 226 "scanner.re" { ++depth; goto comment; } -#line 729 "scanner.c" +#line 728 "scanner.c" yy124: yych = *++YYCURSOR; goto yy125; yy125: -#line 223 "scanner.re" +#line 222 "scanner.re" { if(--depth == 0) goto scan; else goto comment; } -#line 738 "scanner.c" +#line 737 "scanner.c" } -#line 234 "scanner.re" +#line 233 "scanner.re" } diff --git a/tools/re2c/scanner.re b/tools/re2c/scanner.re index 897e518f..81dcf48b 100644 --- a/tools/re2c/scanner.re +++ b/tools/re2c/scanner.re @@ -4,7 +4,6 @@ #include "tools/re2c/parse.h" #include "tools/re2c/globals.h" #include "re2c-parser.h" -#include "globals.h" #ifndef MAX #define MAX(a,b) (((a)>(b))?(a):(b)) -- 2.40.0