Fixed bug with underscores in identifiers
This commit is contained in:
parent
b8bd81f18f
commit
28e8984b72
@ -355,11 +355,11 @@ again:
|
|||||||
register t_idf *id;
|
register t_idf *id;
|
||||||
|
|
||||||
do {
|
do {
|
||||||
if (ch == '_' && *tag == '_') {
|
|
||||||
lexerror("an identifier may not contain two consecutive underscores");
|
|
||||||
}
|
|
||||||
if (tag - buf < idfsize) *tag++ = ch;
|
if (tag - buf < idfsize) *tag++ = ch;
|
||||||
LoadChar(ch);
|
LoadChar(ch);
|
||||||
|
if (ch == '_' && *(tag-1) == '_') {
|
||||||
|
lexerror("an identifier may not contain two consecutive underscores");
|
||||||
|
}
|
||||||
} while(in_idf(ch));
|
} while(in_idf(ch));
|
||||||
|
|
||||||
UnloadChar(ch);
|
UnloadChar(ch);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user