forked from Mirrors/tinycc
tccpp: allow .. in token stream
for gas comments lonely on a line such as
# .. more stuff
where tcc would try to parse .. as a preprocessor directive
See also: 0b3612631f
master
parent
0b3612631f
commit
8dd1859176
11
tccpp.c
11
tccpp.c
|
@ -2549,10 +2549,13 @@ maybe_newline:
|
|||
goto parse_num;
|
||||
} else if (c == '.') {
|
||||
PEEKC(c, p);
|
||||
if (c != '.')
|
||||
expect("'.'");
|
||||
PEEKC(c, p);
|
||||
tok = TOK_DOTS;
|
||||
if (c == '.') {
|
||||
p++;
|
||||
tok = TOK_DOTS;
|
||||
} else {
|
||||
*--p = '.'; /* may underflow into file->unget[] */
|
||||
tok = '.';
|
||||
}
|
||||
} else {
|
||||
tok = '.';
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue