Issue with negative integer scanning
luke-gru opened this issue · 1 comments
luke-gru commented
Hi again 😺
You're probably aware of this already, but the scanner is too eager with scanning the '-' character as being part of an integer instead of an operand. For example:
#include <stdio.h>
int main() {
printf("%d\n",1-1); // can't parse this, as scanner scans this as 2 consecutive T_INTLITs
return (0);
}
Thanks,
DoctorWkt commented
Thanks for the heads-up. I've put a note about it in https://github.com/DoctorWkt/acwj/tree/master/43_More_Operators, but I'll leave it unfixed.