File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1656,15 +1656,15 @@ template or(rules...) if (rules.length > 0)
16561656 failedLength[i] = temp.end;
16571657 if (temp.end >= longestFail.end)
16581658 {
1659+ if (temp.end == longestFail.end)
1660+ errorStringChars += (temp.matches.length > 0 ? temp.matches[$-1].length : 0) + errName.length + 4;
1661+ else
1662+ errorStringChars = (temp.matches.length > 0 ? temp.matches[$-1].length : 0) + errName.length + 4;
16591663 maxFailedLength = temp.end;
16601664 longestFail = temp;
16611665 names[i] = errName;
16621666 results[i] = temp;
16631667
1664- if (temp.end == longestFail.end)
1665- errorStringChars += (temp.matches.length > 0 ? temp.matches[$-1].length : 0) + errName.length + 4;
1666- else
1667- errorStringChars = (temp.matches.length > 0 ? temp.matches[$-1].length : 0) + errName.length + 4;
16681668 }
16691669 // Else, this error parsed less input than another one: we discard it.
16701670 }
You can’t perform that action at this time.
0 commit comments