-/* Generated by re2c 0.15.2 on Sat Nov 28 10:47:09 2015*/
+/* Generated by re2c 0.15.2 on Sat Nov 28 18:04:39 2015*/
#line 1 "../src/parse/lex.re"
#include <stdlib.h>
#include <string.h>
#include <iostream>
+#include <limits>
#include <sstream>
#include "src/ir/dfa/dfa.h"
// source code is in ASCII: pointers have type 'char *'
// but re2c makes an implicit assumption that YYCTYPE is unsigned
// when it generates comparisons
-#line 33 "../src/parse/lex.re"
+#line 34 "../src/parse/lex.re"
-#line 53 "../src/parse/lex.re"
+#line 54 "../src/parse/lex.re"
Scanner::ParseMode Scanner::echo()
tok = cur;
echo:
-#line 53 "src/parse/lex.cc"
+#line 54 "src/parse/lex.cc"
{
YYCTYPE yych;
unsigned int yyaccept = 0;
}
}
++YYCURSOR;
-#line 193 "../src/parse/lex.re"
+#line 194 "../src/parse/lex.re"
{
if (!ignore_eoc && opts->target == opt_t::CODE)
{
return Stop;
}
}
-#line 123 "src/parse/lex.cc"
+#line 124 "src/parse/lex.cc"
yy4:
++YYCURSOR;
yy5:
-#line 204 "../src/parse/lex.re"
+#line 205 "../src/parse/lex.re"
{
goto echo;
}
-#line 131 "src/parse/lex.cc"
+#line 132 "src/parse/lex.cc"
yy6:
yyaccept = 0;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
}
if (yych == '#') goto yy91;
yy7:
-#line 180 "../src/parse/lex.re"
+#line 181 "../src/parse/lex.re"
{
if (ignore_eoc)
{
cline++;
goto echo;
}
-#line 154 "src/parse/lex.cc"
+#line 155 "src/parse/lex.cc"
yy8:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '{') goto yy32;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
++YYCURSOR;
-#line 84 "../src/parse/lex.re"
+#line 85 "../src/parse/lex.re"
{
if (opts->rFlag)
{
tok = cur;
return Rules;
}
-#line 251 "src/parse/lex.cc"
+#line 252 "src/parse/lex.cc"
yy31:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
yy32:
++YYCURSOR;
-#line 69 "../src/parse/lex.re"
+#line 70 "../src/parse/lex.re"
{
if (opts->rFlag)
{
tok = cur;
return Parse;
}
-#line 273 "src/parse/lex.cc"
+#line 274 "src/parse/lex.cc"
yy34:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'e') goto yy12;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
++YYCURSOR;
-#line 96 "../src/parse/lex.re"
+#line 97 "../src/parse/lex.re"
{
if (!opts->rFlag)
{
tok = cur;
return Reuse;
}
-#line 303 "src/parse/lex.cc"
+#line 304 "src/parse/lex.cc"
yy42:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'x') goto yy12;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
++YYCURSOR;
-#line 110 "../src/parse/lex.re"
+#line 111 "../src/parse/lex.re"
{
if (opts->target != opt_t::DOT)
{
ignore_eoc = true;
goto echo;
}
-#line 328 "src/parse/lex.cc"
+#line 329 "src/parse/lex.cc"
yy50:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 't') goto yy12;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
++YYCURSOR;
-#line 119 "../src/parse/lex.re"
+#line 120 "../src/parse/lex.re"
{
tok = pos = cur;
out.wdelay_state_goto (opts->topIndent);
ignore_eoc = true;
goto echo;
}
-#line 360 "src/parse/lex.cc"
+#line 361 "src/parse/lex.cc"
yy63:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'n') goto yy12;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
++YYCURSOR;
-#line 125 "../src/parse/lex.re"
+#line 126 "../src/parse/lex.re"
{
tok = pos = cur;
ignore_eoc = true;
goto echo;
}
-#line 387 "src/parse/lex.cc"
+#line 388 "src/parse/lex.cc"
yy74:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'p') goto yy12;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != 'c') goto yy12;
++YYCURSOR;
-#line 130 "../src/parse/lex.re"
+#line 131 "../src/parse/lex.re"
{
tok = pos = cur;
ignore_eoc = true;
}
goto echo;
}
-#line 418 "src/parse/lex.cc"
+#line 419 "src/parse/lex.cc"
yy84:
yyaccept = 2;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yych == '\n') goto yy87;
if (yych == '\r') goto yy86;
yy85:
-#line 159 "../src/parse/lex.re"
+#line 160 "../src/parse/lex.re"
{
if (ignore_eoc)
{
tok = pos = cur;
goto echo;
}
-#line 443 "src/parse/lex.cc"
+#line 444 "src/parse/lex.cc"
yy86:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != '\n') goto yy12;
yy87:
++YYCURSOR;
-#line 141 "../src/parse/lex.re"
+#line 142 "../src/parse/lex.re"
{
cline++;
if (ignore_eoc)
tok = pos = cur;
goto echo;
}
-#line 468 "src/parse/lex.cc"
+#line 469 "src/parse/lex.cc"
yy89:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yy103:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 176 "../src/parse/lex.re"
+#line 177 "../src/parse/lex.re"
{
set_sourceline ();
goto echo;
}
-#line 548 "src/parse/lex.cc"
+#line 549 "src/parse/lex.cc"
yy105:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '\n') goto yy103;
if (yych == '\r') goto yy105;
goto yy12;
}
-#line 207 "../src/parse/lex.re"
+#line 208 "../src/parse/lex.re"
}
start:
-#line 593 "src/parse/lex.cc"
+#line 594 "src/parse/lex.cc"
{
YYCTYPE yych;
unsigned int yyaccept = 0;
yy112:
++YYCURSOR;
yy113:
-#line 379 "../src/parse/lex.re"
+#line 380 "../src/parse/lex.re"
{
fatalf("unexpected character: '%c'", *tok);
goto scan;
}
-#line 713 "src/parse/lex.cc"
+#line 714 "src/parse/lex.cc"
yy114:
++YYCURSOR;
yych = (YYCTYPE)*YYCURSOR;
goto yy220;
yy115:
-#line 363 "../src/parse/lex.re"
+#line 364 "../src/parse/lex.re"
{
goto scan;
}
-#line 723 "src/parse/lex.cc"
+#line 724 "src/parse/lex.cc"
yy116:
yyaccept = 0;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yych == '#') goto yy200;
}
yy117:
-#line 372 "../src/parse/lex.re"
+#line 373 "../src/parse/lex.re"
{
if (cur == eof) return 0;
pos = cur;
cline++;
goto scan;
}
-#line 741 "src/parse/lex.cc"
+#line 742 "src/parse/lex.cc"
yy118:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '\n') goto yy197;
goto yy113;
yy119:
++YYCURSOR;
-#line 256 "../src/parse/lex.re"
+#line 257 "../src/parse/lex.re"
{ yylval.regexp = lex_str('"', opts->bCaseInsensitive || opts->bCaseInverted); return REGEXP; }
-#line 750 "src/parse/lex.cc"
+#line 751 "src/parse/lex.cc"
yy121:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '}') goto yy195;
goto yy113;
yy122:
++YYCURSOR;
-#line 255 "../src/parse/lex.re"
+#line 256 "../src/parse/lex.re"
{ yylval.regexp = lex_str('\'', opts->bCaseInsensitive || !opts->bCaseInverted); return REGEXP; }
-#line 759 "src/parse/lex.cc"
+#line 760 "src/parse/lex.cc"
yy124:
++YYCURSOR;
yy125:
-#line 266 "../src/parse/lex.re"
+#line 267 "../src/parse/lex.re"
{
return *tok;
}
-#line 767 "src/parse/lex.cc"
+#line 768 "src/parse/lex.cc"
yy126:
++YYCURSOR;
if ((yych = (YYCTYPE)*YYCURSOR) == '/') goto yy195;
-#line 270 "../src/parse/lex.re"
+#line 271 "../src/parse/lex.re"
{
yylval.op = *tok;
return STAR;
}
-#line 776 "src/parse/lex.cc"
+#line 777 "src/parse/lex.cc"
yy128:
++YYCURSOR;
-#line 274 "../src/parse/lex.re"
+#line 275 "../src/parse/lex.re"
{
yylval.op = *tok;
return CLOSE;
}
-#line 784 "src/parse/lex.cc"
+#line 785 "src/parse/lex.cc"
yy130:
++YYCURSOR;
-#line 358 "../src/parse/lex.re"
+#line 359 "../src/parse/lex.re"
{
yylval.regexp = mkDot();
return REGEXP;
}
-#line 792 "src/parse/lex.cc"
+#line 793 "src/parse/lex.cc"
yy132:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '*') goto yy191;
yy136:
++YYCURSOR;
if ((yych = (YYCTYPE)*YYCURSOR) == '^') goto yy176;
-#line 257 "../src/parse/lex.re"
+#line 258 "../src/parse/lex.re"
{ yylval.regexp = lex_cls(false); return REGEXP; }
-#line 818 "src/parse/lex.cc"
+#line 819 "src/parse/lex.cc"
yy138:
yych = (YYCTYPE)*++YYCURSOR;
YYCTXMARKER = YYCURSOR;
}
}
yy140:
-#line 226 "../src/parse/lex.re"
+#line 227 "../src/parse/lex.re"
{
depth = 1;
goto code;
}
-#line 847 "src/parse/lex.cc"
+#line 848 "src/parse/lex.cc"
yy141:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yy146:
++YYCURSOR;
yy147:
-#line 310 "../src/parse/lex.re"
+#line 311 "../src/parse/lex.re"
{
fatal("illegal closure form, use '{n}', '{n,}', '{n,m}' where n and m are numbers");
}
-#line 900 "src/parse/lex.cc"
+#line 901 "src/parse/lex.cc"
yy148:
++YYCURSOR;
-#line 314 "../src/parse/lex.re"
+#line 315 "../src/parse/lex.re"
{
if (!opts->FFlag) {
fatal("curly braces for names only allowed with -F switch");
yylval.str = new std::string (tok + 1, tok_len () - 2); // -2 to omit braces
return ID;
}
-#line 911 "src/parse/lex.cc"
+#line 912 "src/parse/lex.cc"
yy150:
++YYCURSOR;
-#line 279 "../src/parse/lex.re"
+#line 280 "../src/parse/lex.re"
{
if (!s_to_u32_unsafe (tok + 1, cur - 1, yylval.extop.min))
{
yylval.extop.max = yylval.extop.min;
return CLOSESIZE;
}
-#line 923 "src/parse/lex.cc"
+#line 924 "src/parse/lex.cc"
yy152:
yyaccept = 3;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yych <= '9') goto yy155;
if (yych != '}') goto yy147;
++YYCURSOR;
-#line 301 "../src/parse/lex.re"
+#line 302 "../src/parse/lex.re"
{
if (!s_to_u32_unsafe (tok + 1, cur - 2, yylval.extop.min))
{
fatal ("repetition lower bound overflow");
}
- yylval.extop.max = UINT32_MAX;
+ yylval.extop.max = std::numeric_limits<uint32_t>::max();
return CLOSESIZE;
}
-#line 940 "src/parse/lex.cc"
+#line 941 "src/parse/lex.cc"
yy155:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
if (yych <= '9') goto yy155;
if (yych != '}') goto yy143;
++YYCURSOR;
-#line 288 "../src/parse/lex.re"
+#line 289 "../src/parse/lex.re"
{
const char * p = strchr (tok, ',');
if (!s_to_u32_unsafe (tok + 1, p, yylval.extop.min))
}
return CLOSESIZE;
}
-#line 962 "src/parse/lex.cc"
+#line 963 "src/parse/lex.cc"
yy159:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 342 "../src/parse/lex.re"
+#line 343 "../src/parse/lex.re"
{
if (!opts->FFlag) {
yylval.str = new std::string (tok, tok_len());
return REGEXP;
}
}
-#line 982 "src/parse/lex.cc"
+#line 983 "src/parse/lex.cc"
yy161:
yych = (YYCTYPE)*++YYCURSOR;
goto yy174;
++YYCURSOR;
yy163:
YYCURSOR = YYCTXMARKER;
-#line 337 "../src/parse/lex.re"
+#line 338 "../src/parse/lex.re"
{
yylval.str = new std::string (tok, tok_len ());
return ID;
}
-#line 995 "src/parse/lex.cc"
+#line 996 "src/parse/lex.cc"
yy164:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
YYCTXMARKER = YYCURSOR;
if (yych != ':') goto yy165;
++YYCURSOR;
-#line 322 "../src/parse/lex.re"
+#line 323 "../src/parse/lex.re"
{ lex_conf (); return CONF; }
-#line 1042 "src/parse/lex.cc"
+#line 1043 "src/parse/lex.cc"
yy171:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 324 "../src/parse/lex.re"
+#line 325 "../src/parse/lex.re"
{
yylval.str = new std::string (tok, tok_len ());
if (opts->FFlag)
return ID;
}
}
-#line 1059 "src/parse/lex.cc"
+#line 1060 "src/parse/lex.cc"
yy173:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
goto yy163;
yy176:
++YYCURSOR;
-#line 258 "../src/parse/lex.re"
+#line 259 "../src/parse/lex.re"
{ yylval.regexp = lex_cls(true); return REGEXP; }
-#line 1078 "src/parse/lex.cc"
+#line 1079 "src/parse/lex.cc"
yy178:
++YYCURSOR;
-#line 263 "../src/parse/lex.re"
+#line 264 "../src/parse/lex.re"
{
return SETUP;
}
-#line 1085 "src/parse/lex.cc"
+#line 1086 "src/parse/lex.cc"
yy180:
yych = (YYCTYPE)*++YYCURSOR;
YYCTXMARKER = YYCURSOR;
yy183:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 260 "../src/parse/lex.re"
+#line 261 "../src/parse/lex.re"
{
return NOCOND;
}
-#line 1119 "src/parse/lex.cc"
+#line 1120 "src/parse/lex.cc"
yy185:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '>') goto yy183;
yy187:
++YYCURSOR;
if ((yych = (YYCTYPE)*YYCURSOR) == '>') goto yy189;
-#line 235 "../src/parse/lex.re"
+#line 236 "../src/parse/lex.re"
{
tok += 2; /* skip ":=" */
depth = 0;
goto code;
}
-#line 1137 "src/parse/lex.cc"
+#line 1138 "src/parse/lex.cc"
yy189:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 231 "../src/parse/lex.re"
+#line 232 "../src/parse/lex.re"
{
return *tok;
}
-#line 1145 "src/parse/lex.cc"
+#line 1146 "src/parse/lex.cc"
yy191:
++YYCURSOR;
-#line 244 "../src/parse/lex.re"
+#line 245 "../src/parse/lex.re"
{
depth = 1;
goto comment;
}
-#line 1153 "src/parse/lex.cc"
+#line 1154 "src/parse/lex.cc"
yy193:
++YYCURSOR;
-#line 241 "../src/parse/lex.re"
+#line 242 "../src/parse/lex.re"
{
goto nextLine;
}
-#line 1160 "src/parse/lex.cc"
+#line 1161 "src/parse/lex.cc"
yy195:
++YYCURSOR;
-#line 250 "../src/parse/lex.re"
+#line 251 "../src/parse/lex.re"
{
tok = cur;
return 0;
}
-#line 1168 "src/parse/lex.cc"
+#line 1169 "src/parse/lex.cc"
yy197:
yyaccept = 0;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
yy212:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 367 "../src/parse/lex.re"
+#line 368 "../src/parse/lex.re"
{
set_sourceline ();
goto scan;
}
-#line 1266 "src/parse/lex.cc"
+#line 1267 "src/parse/lex.cc"
yy214:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '\n') goto yy212;
if (yych == ' ') goto yy219;
goto yy115;
}
-#line 383 "../src/parse/lex.re"
+#line 384 "../src/parse/lex.re"
flex_name:
-#line 1304 "src/parse/lex.cc"
+#line 1305 "src/parse/lex.cc"
{
YYCTYPE yych;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
if (yych == '\r') goto yy227;
++YYCURSOR;
yy224:
-#line 394 "../src/parse/lex.re"
+#line 395 "../src/parse/lex.re"
{
YYCURSOR = tok;
goto start;
}
-#line 1318 "src/parse/lex.cc"
+#line 1319 "src/parse/lex.cc"
yy225:
++YYCURSOR;
yy226:
-#line 388 "../src/parse/lex.re"
+#line 389 "../src/parse/lex.re"
{
YYCURSOR = tok;
lexer_state = LEX_NORMAL;
return FID_END;
}
-#line 1328 "src/parse/lex.cc"
+#line 1329 "src/parse/lex.cc"
yy227:
yych = (YYCTYPE)*++YYCURSOR;
if (yych != '\n') goto yy224;
yych = (YYCTYPE)*YYCURSOR;
goto yy226;
}
-#line 398 "../src/parse/lex.re"
+#line 399 "../src/parse/lex.re"
code:
-#line 1341 "src/parse/lex.cc"
+#line 1342 "src/parse/lex.cc"
{
YYCTYPE yych;
unsigned int yyaccept = 0;
}
yy231:
++YYCURSOR;
-#line 461 "../src/parse/lex.re"
+#line 462 "../src/parse/lex.re"
{
if (cur == eof)
{
}
goto code;
}
-#line 1414 "src/parse/lex.cc"
+#line 1415 "src/parse/lex.cc"
yy233:
++YYCURSOR;
yy234:
-#line 475 "../src/parse/lex.re"
+#line 476 "../src/parse/lex.re"
{
goto code;
}
-#line 1422 "src/parse/lex.cc"
+#line 1423 "src/parse/lex.cc"
yy235:
yyaccept = 0;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
}
}
yy236:
-#line 442 "../src/parse/lex.re"
+#line 443 "../src/parse/lex.re"
{
if (depth == 0)
{
cline++;
goto code;
}
-#line 1462 "src/parse/lex.cc"
+#line 1463 "src/parse/lex.cc"
yy237:
yyaccept = 1;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
goto yy244;
yy239:
++YYCURSOR;
-#line 414 "../src/parse/lex.re"
+#line 415 "../src/parse/lex.re"
{
if (depth == 0)
{
}
goto code;
}
-#line 1487 "src/parse/lex.cc"
+#line 1488 "src/parse/lex.cc"
yy241:
++YYCURSOR;
-#line 402 "../src/parse/lex.re"
+#line 403 "../src/parse/lex.re"
{
if (depth == 0)
{
}
goto code;
}
-#line 1503 "src/parse/lex.cc"
+#line 1504 "src/parse/lex.cc"
yy243:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
goto yy243;
yy247:
++YYCURSOR;
-#line 472 "../src/parse/lex.re"
+#line 473 "../src/parse/lex.re"
{
goto code;
}
-#line 1538 "src/parse/lex.cc"
+#line 1539 "src/parse/lex.cc"
yy249:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
}
yy253:
YYCURSOR = YYCTXMARKER;
-#line 429 "../src/parse/lex.re"
+#line 430 "../src/parse/lex.re"
{
if (depth == 0)
{
cline++;
goto code;
}
-#line 1579 "src/parse/lex.cc"
+#line 1580 "src/parse/lex.cc"
yy254:
yych = (YYCTYPE)*++YYCURSOR;
goto yy253;
yy267:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 425 "../src/parse/lex.re"
+#line 426 "../src/parse/lex.re"
{
set_sourceline ();
goto code;
}
-#line 1651 "src/parse/lex.cc"
+#line 1652 "src/parse/lex.cc"
yy269:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '\n') goto yy267;
goto yy245;
}
}
-#line 478 "../src/parse/lex.re"
+#line 479 "../src/parse/lex.re"
comment:
-#line 1695 "src/parse/lex.cc"
+#line 1696 "src/parse/lex.cc"
{
YYCTYPE yych;
static const unsigned char yybm[] = {
}
++YYCURSOR;
yy279:
-#line 510 "../src/parse/lex.re"
+#line 511 "../src/parse/lex.re"
{
if (cur == eof)
{
}
goto comment;
}
-#line 1750 "src/parse/lex.cc"
+#line 1751 "src/parse/lex.cc"
yy280:
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yybm[0+yych] & 32) {
}
if (yych == '#') goto yy291;
yy281:
-#line 501 "../src/parse/lex.re"
+#line 502 "../src/parse/lex.re"
{
if (cur == eof)
{
cline++;
goto comment;
}
-#line 1768 "src/parse/lex.cc"
+#line 1769 "src/parse/lex.cc"
yy282:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '/') goto yy286;
yych = (YYCTYPE)*++YYCURSOR;
if (yych != '*') goto yy279;
++YYCURSOR;
-#line 492 "../src/parse/lex.re"
+#line 493 "../src/parse/lex.re"
{
++depth;
fatal("ambiguous /* found");
goto comment;
}
-#line 1783 "src/parse/lex.cc"
+#line 1784 "src/parse/lex.cc"
yy286:
++YYCURSOR;
-#line 482 "../src/parse/lex.re"
+#line 483 "../src/parse/lex.re"
{
if (--depth == 0)
{
goto comment;
}
}
-#line 1797 "src/parse/lex.cc"
+#line 1798 "src/parse/lex.cc"
yy288:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yy303:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 497 "../src/parse/lex.re"
+#line 498 "../src/parse/lex.re"
{
set_sourceline ();
goto comment;
}
-#line 1880 "src/parse/lex.cc"
+#line 1881 "src/parse/lex.cc"
yy305:
yych = (YYCTYPE)*++YYCURSOR;
if (yych == '\n') goto yy303;
if (yych == '\r') goto yy305;
goto yy290;
}
-#line 517 "../src/parse/lex.re"
+#line 518 "../src/parse/lex.re"
nextLine:
-#line 1910 "src/parse/lex.cc"
+#line 1911 "src/parse/lex.cc"
{
YYCTYPE yych;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = (YYCTYPE)*YYCURSOR;
if (yych == '\n') goto yy314;
++YYCURSOR;
-#line 528 "../src/parse/lex.re"
+#line 529 "../src/parse/lex.re"
{ if(cur == eof) {
return 0;
}
goto nextLine;
}
-#line 1923 "src/parse/lex.cc"
+#line 1924 "src/parse/lex.cc"
yy314:
++YYCURSOR;
-#line 521 "../src/parse/lex.re"
+#line 522 "../src/parse/lex.re"
{ if(cur == eof) {
return 0;
}
cline++;
goto scan;
}
-#line 1934 "src/parse/lex.cc"
+#line 1935 "src/parse/lex.cc"
}
-#line 533 "../src/parse/lex.re"
+#line 534 "../src/parse/lex.re"
}
uint32_t u, l;
fst:
-#line 1960 "src/parse/lex.cc"
+#line 1961 "src/parse/lex.cc"
{
YYCTYPE yych;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = (YYCTYPE)*YYCURSOR;
if (yych == ']') goto yy319;
-#line 557 "../src/parse/lex.re"
+#line 558 "../src/parse/lex.re"
{ l = lex_cls_chr(); goto snd; }
-#line 1968 "src/parse/lex.cc"
+#line 1969 "src/parse/lex.cc"
yy319:
++YYCURSOR;
-#line 556 "../src/parse/lex.re"
+#line 557 "../src/parse/lex.re"
{ goto end; }
-#line 1973 "src/parse/lex.cc"
+#line 1974 "src/parse/lex.cc"
}
-#line 558 "../src/parse/lex.re"
+#line 559 "../src/parse/lex.re"
snd:
-#line 1979 "src/parse/lex.cc"
+#line 1980 "src/parse/lex.cc"
{
YYCTYPE yych;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = (YYCTYPE)*(YYMARKER = YYCURSOR);
if (yych == '-') goto yy324;
yy323:
-#line 561 "../src/parse/lex.re"
+#line 562 "../src/parse/lex.re"
{ u = l; goto add; }
-#line 1988 "src/parse/lex.cc"
+#line 1989 "src/parse/lex.cc"
yy324:
yych = (YYCTYPE)*++YYCURSOR;
YYCTXMARKER = YYCURSOR;
yy326:
++YYCURSOR;
YYCURSOR = YYCTXMARKER;
-#line 562 "../src/parse/lex.re"
+#line 563 "../src/parse/lex.re"
{
u = lex_cls_chr();
if (l > u) {
}
goto add;
}
-#line 2007 "src/parse/lex.cc"
+#line 2008 "src/parse/lex.cc"
}
-#line 570 "../src/parse/lex.re"
+#line 571 "../src/parse/lex.re"
add:
if (!(s = opts->encoding.encodeRange(l, u))) {
{
tok = cur;
-#line 2028 "src/parse/lex.cc"
+#line 2029 "src/parse/lex.cc"
{
YYCTYPE yych;
unsigned int yyaccept = 0;
if (yych == '\n') goto yy332;
if (yych == '\\') goto yy334;
++YYCURSOR;
-#line 593 "../src/parse/lex.re"
+#line 594 "../src/parse/lex.re"
{ return static_cast<uint8_t>(tok[0]); }
-#line 2039 "src/parse/lex.cc"
+#line 2040 "src/parse/lex.cc"
yy332:
++YYCURSOR;
-#line 588 "../src/parse/lex.re"
+#line 589 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error"); }
-#line 2044 "src/parse/lex.cc"
+#line 2045 "src/parse/lex.cc"
yy334:
++YYCURSOR;
if ((yych = (YYCTYPE)*YYCURSOR) <= '`') {
}
}
}
-#line 591 "../src/parse/lex.re"
+#line 592 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error in escape sequence"); }
-#line 2095 "src/parse/lex.cc"
+#line 2096 "src/parse/lex.cc"
yy336:
++YYCURSOR;
-#line 606 "../src/parse/lex.re"
+#line 607 "../src/parse/lex.re"
{
warn.useless_escape(tline, tok - pos, tok[1]);
return static_cast<uint8_t>(tok[1]);
}
-#line 2103 "src/parse/lex.cc"
+#line 2104 "src/parse/lex.cc"
yy338:
++YYCURSOR;
-#line 604 "../src/parse/lex.re"
+#line 605 "../src/parse/lex.re"
{ return static_cast<uint8_t>('-'); }
-#line 2108 "src/parse/lex.cc"
+#line 2109 "src/parse/lex.cc"
yy340:
yyaccept = 0;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yych <= '/') goto yy341;
if (yych <= '7') goto yy379;
yy341:
-#line 590 "../src/parse/lex.re"
+#line 591 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error in octal escape sequence"); }
-#line 2117 "src/parse/lex.cc"
+#line 2118 "src/parse/lex.cc"
yy342:
yych = (YYCTYPE)*++YYCURSOR;
goto yy341;
if (yych <= 'f') goto yy372;
}
yy344:
-#line 589 "../src/parse/lex.re"
+#line 590 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error in hexadecimal escape sequence"); }
-#line 2135 "src/parse/lex.cc"
+#line 2136 "src/parse/lex.cc"
yy345:
yyaccept = 1;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
}
yy346:
++YYCURSOR;
-#line 603 "../src/parse/lex.re"
+#line 604 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\\'); }
-#line 2153 "src/parse/lex.cc"
+#line 2154 "src/parse/lex.cc"
yy348:
++YYCURSOR;
-#line 605 "../src/parse/lex.re"
+#line 606 "../src/parse/lex.re"
{ return static_cast<uint8_t>(']'); }
-#line 2158 "src/parse/lex.cc"
+#line 2159 "src/parse/lex.cc"
yy350:
++YYCURSOR;
-#line 596 "../src/parse/lex.re"
+#line 597 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\a'); }
-#line 2163 "src/parse/lex.cc"
+#line 2164 "src/parse/lex.cc"
yy352:
++YYCURSOR;
-#line 597 "../src/parse/lex.re"
+#line 598 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\b'); }
-#line 2168 "src/parse/lex.cc"
+#line 2169 "src/parse/lex.cc"
yy354:
++YYCURSOR;
-#line 598 "../src/parse/lex.re"
+#line 599 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\f'); }
-#line 2173 "src/parse/lex.cc"
+#line 2174 "src/parse/lex.cc"
yy356:
++YYCURSOR;
-#line 599 "../src/parse/lex.re"
+#line 600 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\n'); }
-#line 2178 "src/parse/lex.cc"
+#line 2179 "src/parse/lex.cc"
yy358:
++YYCURSOR;
-#line 600 "../src/parse/lex.re"
+#line 601 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\r'); }
-#line 2183 "src/parse/lex.cc"
+#line 2184 "src/parse/lex.cc"
yy360:
++YYCURSOR;
-#line 601 "../src/parse/lex.re"
+#line 602 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\t'); }
-#line 2188 "src/parse/lex.cc"
+#line 2189 "src/parse/lex.cc"
yy362:
++YYCURSOR;
-#line 602 "../src/parse/lex.re"
+#line 603 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\v'); }
-#line 2193 "src/parse/lex.cc"
+#line 2194 "src/parse/lex.cc"
yy364:
yyaccept = 1;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
}
yy367:
++YYCURSOR;
-#line 594 "../src/parse/lex.re"
+#line 595 "../src/parse/lex.re"
{ return unesc_hex(tok, cur); }
-#line 2226 "src/parse/lex.cc"
+#line 2227 "src/parse/lex.cc"
yy369:
yych = (YYCTYPE)*++YYCURSOR;
if (yych <= '@') {
if (yych <= '/') goto yy366;
if (yych >= '8') goto yy366;
++YYCURSOR;
-#line 595 "../src/parse/lex.re"
+#line 596 "../src/parse/lex.re"
{ return unesc_oct(tok, cur); }
-#line 2338 "src/parse/lex.cc"
+#line 2339 "src/parse/lex.cc"
}
-#line 610 "../src/parse/lex.re"
+#line 611 "../src/parse/lex.re"
}
end = false;
tok = cur;
-#line 2349 "src/parse/lex.cc"
+#line 2350 "src/parse/lex.cc"
{
YYCTYPE yych;
unsigned int yyaccept = 0;
if (yych == '\n') goto yy386;
if (yych == '\\') goto yy388;
++YYCURSOR;
-#line 623 "../src/parse/lex.re"
+#line 624 "../src/parse/lex.re"
{
end = tok[0] == quote;
return static_cast<uint8_t>(tok[0]);
}
-#line 2363 "src/parse/lex.cc"
+#line 2364 "src/parse/lex.cc"
yy386:
++YYCURSOR;
-#line 618 "../src/parse/lex.re"
+#line 619 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error"); }
-#line 2368 "src/parse/lex.cc"
+#line 2369 "src/parse/lex.cc"
yy388:
++YYCURSOR;
if ((yych = (YYCTYPE)*YYCURSOR) <= 'a') {
}
}
}
-#line 621 "../src/parse/lex.re"
+#line 622 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error in escape sequence"); }
-#line 2416 "src/parse/lex.cc"
+#line 2417 "src/parse/lex.cc"
yy390:
++YYCURSOR;
-#line 637 "../src/parse/lex.re"
+#line 638 "../src/parse/lex.re"
{
if (tok[1] != quote) {
warn.useless_escape(tline, tok - pos, tok[1]);
}
return static_cast<uint8_t>(tok[1]);
}
-#line 2426 "src/parse/lex.cc"
+#line 2427 "src/parse/lex.cc"
yy392:
yyaccept = 0;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yych <= '/') goto yy393;
if (yych <= '7') goto yy429;
yy393:
-#line 620 "../src/parse/lex.re"
+#line 621 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error in octal escape sequence"); }
-#line 2435 "src/parse/lex.cc"
+#line 2436 "src/parse/lex.cc"
yy394:
yych = (YYCTYPE)*++YYCURSOR;
goto yy393;
if (yych <= 'f') goto yy422;
}
yy396:
-#line 619 "../src/parse/lex.re"
+#line 620 "../src/parse/lex.re"
{ fatal ((tok - pos) - tchar, "syntax error in hexadecimal escape sequence"); }
-#line 2453 "src/parse/lex.cc"
+#line 2454 "src/parse/lex.cc"
yy397:
yyaccept = 1;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
}
yy398:
++YYCURSOR;
-#line 636 "../src/parse/lex.re"
+#line 637 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\\'); }
-#line 2471 "src/parse/lex.cc"
+#line 2472 "src/parse/lex.cc"
yy400:
++YYCURSOR;
-#line 629 "../src/parse/lex.re"
+#line 630 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\a'); }
-#line 2476 "src/parse/lex.cc"
+#line 2477 "src/parse/lex.cc"
yy402:
++YYCURSOR;
-#line 630 "../src/parse/lex.re"
+#line 631 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\b'); }
-#line 2481 "src/parse/lex.cc"
+#line 2482 "src/parse/lex.cc"
yy404:
++YYCURSOR;
-#line 631 "../src/parse/lex.re"
+#line 632 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\f'); }
-#line 2486 "src/parse/lex.cc"
+#line 2487 "src/parse/lex.cc"
yy406:
++YYCURSOR;
-#line 632 "../src/parse/lex.re"
+#line 633 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\n'); }
-#line 2491 "src/parse/lex.cc"
+#line 2492 "src/parse/lex.cc"
yy408:
++YYCURSOR;
-#line 633 "../src/parse/lex.re"
+#line 634 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\r'); }
-#line 2496 "src/parse/lex.cc"
+#line 2497 "src/parse/lex.cc"
yy410:
++YYCURSOR;
-#line 634 "../src/parse/lex.re"
+#line 635 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\t'); }
-#line 2501 "src/parse/lex.cc"
+#line 2502 "src/parse/lex.cc"
yy412:
++YYCURSOR;
-#line 635 "../src/parse/lex.re"
+#line 636 "../src/parse/lex.re"
{ return static_cast<uint8_t>('\v'); }
-#line 2506 "src/parse/lex.cc"
+#line 2507 "src/parse/lex.cc"
yy414:
yyaccept = 1;
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
}
yy417:
++YYCURSOR;
-#line 627 "../src/parse/lex.re"
+#line 628 "../src/parse/lex.re"
{ return unesc_hex(tok, cur); }
-#line 2539 "src/parse/lex.cc"
+#line 2540 "src/parse/lex.cc"
yy419:
yych = (YYCTYPE)*++YYCURSOR;
if (yych <= '@') {
if (yych <= '/') goto yy416;
if (yych >= '8') goto yy416;
++YYCURSOR;
-#line 628 "../src/parse/lex.re"
+#line 629 "../src/parse/lex.re"
{ return unesc_oct(tok, cur); }
-#line 2651 "src/parse/lex.cc"
+#line 2652 "src/parse/lex.cc"
}
-#line 643 "../src/parse/lex.re"
+#line 644 "../src/parse/lex.re"
}
sourceline:
tok = cur;
-#line 2674 "src/parse/lex.cc"
+#line 2675 "src/parse/lex.cc"
{
YYCTYPE yych;
static const unsigned char yybm[] = {
yy434:
++YYCURSOR;
yy435:
-#line 686 "../src/parse/lex.re"
+#line 687 "../src/parse/lex.re"
{
goto sourceline;
}
-#line 2727 "src/parse/lex.cc"
+#line 2728 "src/parse/lex.cc"
yy436:
++YYCURSOR;
-#line 674 "../src/parse/lex.re"
+#line 675 "../src/parse/lex.re"
{
if (cur == eof)
{
tok = cur;
return;
}
-#line 2743 "src/parse/lex.cc"
+#line 2744 "src/parse/lex.cc"
yy438:
yych = (YYCTYPE)*(YYMARKER = ++YYCURSOR);
if (yych == '\n') goto yy435;
yych = (YYCTYPE)*YYCURSOR;
goto yy442;
yy440:
-#line 663 "../src/parse/lex.re"
+#line 664 "../src/parse/lex.re"
{
if (!s_to_u32_unsafe (tok, cur, cline))
{
}
goto sourceline;
}
-#line 2761 "src/parse/lex.cc"
+#line 2762 "src/parse/lex.cc"
yy441:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
goto yy443;
yy447:
++YYCURSOR;
-#line 670 "../src/parse/lex.re"
+#line 671 "../src/parse/lex.re"
{
escape (in.file_name, std::string (tok + 1, tok_len () - 2)); // -2 to omit quotes
goto sourceline;
}
-#line 2798 "src/parse/lex.cc"
+#line 2799 "src/parse/lex.cc"
}
-#line 689 "../src/parse/lex.re"
+#line 690 "../src/parse/lex.re"
}