allprint prototype correction for 8-bit cleanness weird debug message fix (my case was negative input() return values of pic) Notes: Sun Jan 29 11:20:18 EST 2006 rsc thanks! Reference: /n/sources/patch/applied/lex-debug Date: Sat Jan 28 17:27:50 CET 2006 Reviewed-by: rsc --- /sys/src/cmd/lex/ncform Sat Jan 28 17:27:48 2006 +++ /sys/src/cmd/lex/ncform Sat Jan 28 17:27:43 2006 @@ -9,7 +9,7 @@ extern struct yysvf *yyestate; int yyprevious = YYNEWLINE; # ifdef LEXDEBUG -extern void allprint(char); +extern void allprint(int); # endif yylook(void){ struct yysvf *yystate, **lsp; @@ -113,7 +113,7 @@ } # ifdef LEXDEBUG if(debug){ - fprintf(yyout,"stopped at %d with ",*(lsp-1)-yysvec-1); + fprintf(yyout,"stopped at %d with ",lsp>yylstate?*(lsp-1)-yysvec-1:0); allprint(yych); putchar('\n'); }