]> vcs.slashdirt.org Git - sw/tic2json.git/commitdiff

vcs.slashdirt.org Git - sw/tic2json.git/commitdiff

git git / sw / tic2json.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3862c99)
don't report errors in lexers by default v2.0
2021年8月26日 10:16:09 +0000 (12:16 +0200)
2021年8月26日 10:17:06 +0000 (12:17 +0200)
The parser will take care of that anyway. This reduces chatter during
initial sync.
Errors will still be reported in debug mode.


diff --git a/ticv01.l b/ticv01.l
index 12dc4b392401029298deb9056dd1550c9e171df7..45b9edab6b9a53cbe94faa073a375cb5f2d89b8b 100644 (file)
--- a/ticv01.l
+++ b/ticv01.l
@@ -139,7 +139,7 @@ AUTRE { crc_calc(); ticv01yylval.label = "AUTRE"; return ET_AUTRE; }
<DATA>{DATAC}+ { crc_calc(); ticv01yylval.text = strdup(yytext); return TOK_DATA; }
-<*>. { pr_err("spurious character 0x%02hhx\n", *yytext); return *yytext; }
+<*>. { if (yy_flex_debug) pr_err("spurious character 0x%02hhx\n", *yytext); return *yytext; }
<<EOF>> { yyterminate(); }
%%
diff --git a/ticv02.l b/ticv02.l
index a81f6caec7916bda3288fe87e9d65f8ef54ca4ba..3396a888054989188e9599d8a20a39d2888bb35b 100644 (file)
--- a/ticv02.l
+++ b/ticv02.l
@@ -157,7 +157,7 @@ PPOINTE { crc_calc(); ticv02yylval.label = "PPOINTE"; return ET_PPOINTE; }
<DATA>{HORODATE} { crc_calc(); ticv02yylval.text = strdup(yytext); return TOK_HDATE; }
<DATA>{DATAC}+ { crc_calc(); ticv02yylval.text = strdup(yytext); return TOK_DATA; }
-<*>. { pr_err("spurious character 0x%02hhx\n", *yytext); return *yytext; }
+<*>. { if (yy_flex_debug) pr_err("spurious character 0x%02hhx\n", *yytext); return *yytext; }
<<EOF>> { yyterminate(); }
%%
tic2json TIC parser/converter
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /