mirror of
https://github.com/verilator/verilator.git
synced 2025-01-08 15:47:36 +00:00
One or two digit octal escapes are legal
This commit is contained in:
parent
d6884db439
commit
d962dfe48c
@ -1463,8 +1463,12 @@ string V3Parse::deQuote(FileLine* fileline, string text) {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (octal_digits) {
|
if (octal_digits) {
|
||||||
fileline->v3error("Non-three digit octal escape code (\\###)");
|
// Spec allows 1-3 digits
|
||||||
octal_digits = 0;
|
octal_digits = 0;
|
||||||
|
quoted = false;
|
||||||
|
newtext += octal_val;
|
||||||
|
--cp; // Backup to reprocess terminating character as non-escaped
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
quoted = false;
|
quoted = false;
|
||||||
if (*cp == 'n') newtext += '\n';
|
if (*cp == 'n') newtext += '\n';
|
||||||
|
Loading…
Reference in New Issue
Block a user