Merge branch 'fix-lalr_bugs' into iterative
This commit is contained in:
commit
e385e0e5de
5 changed files with 79 additions and 14 deletions
|
|
@ -677,7 +677,7 @@ static void stringset_extend(HCFGrammar *g, HStringMap *ret,
|
|||
}
|
||||
|
||||
|
||||
void h_pprint_char(FILE *f, char c)
|
||||
void h_pprint_char(FILE *f, uint8_t c)
|
||||
{
|
||||
switch(c) {
|
||||
case '"': fputs("\\\"", f); break;
|
||||
|
|
@ -690,12 +690,12 @@ void h_pprint_char(FILE *f, char c)
|
|||
if (isprint((int)c)) {
|
||||
fputc(c, f);
|
||||
} else {
|
||||
fprintf(f, "\\x%.2X", c);
|
||||
fprintf(f, "\\x%.2X", (unsigned int)c);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void pprint_charset_char(FILE *f, char c)
|
||||
static void pprint_charset_char(FILE *f, uint8_t c)
|
||||
{
|
||||
switch(c) {
|
||||
case '"': fputc(c, f); break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue