Revert "Fixed error posision problem in Repetition operator"

This reverts commit 6ed41b0571.
This commit is contained in:
yhirose 2021-01-08 14:23:58 -05:00
parent 6ed41b0571
commit 222466d07a
2 changed files with 2 additions and 0 deletions

Binary file not shown.

View File

@ -901,6 +901,7 @@ public:
count++; count++;
} }
auto save_error_pos = c.error_pos;
while (n - i > 0 && count < max_) { while (n - i > 0 && count < max_) {
c.push_capture_scope(); c.push_capture_scope();
auto se = scope_exit([&]() { c.pop_capture_scope(); }); auto se = scope_exit([&]() { c.pop_capture_scope(); });
@ -920,6 +921,7 @@ public:
vs.tokens.erase(vs.tokens.begin() + vs.tokens.erase(vs.tokens.begin() +
static_cast<std::ptrdiff_t>(save_tok_size)); static_cast<std::ptrdiff_t>(save_tok_size));
} }
c.error_pos = save_error_pos;
break; break;
} }
i += len; i += len;