simpler octal escape pattern

This commit is contained in:
Josh Holtrop 2018-04-11 21:39:21 -04:00
parent 5615c5781d
commit 50480d80b4

View File

@ -143,7 +143,7 @@ L?\" {
char v[2] = {(char)val, '\0'};
String_concat(build_string, v);
}
\\[0-7][0-7]?[0-7]? {
\\[0-7]{1,3} {
/* octal escape code */
unsigned int val;
(void)sscanf(yytext + 1, "%o", &val);