From 6ed41b05718fe9deb5b958dc4c491dd16d9b694a Mon Sep 17 00:00:00 2001 From: yhirose Date: Fri, 8 Jan 2021 14:06:32 -0500 Subject: [PATCH] Fixed error posision problem in Repetition operator --- docs/native.wasm | Bin 349328 -> 349314 bytes peglib.h | 2 -- 2 files changed, 2 deletions(-) diff --git a/docs/native.wasm b/docs/native.wasm index 2f0b1c3b7c8809df757fd394f5c455b7907a4a4e..d31bbfd86c7d88ba427d812cfd283c14a1878243 100644 GIT binary patch delta 181 zcmbQRQnYEM=!PXcj9WG@<(X^BxMZ`l(~^gbtJ+^EGXgOa5HoLoq0F+Eg>lvPWg0Ao z=8Vs_--u^9&&+s!`-)_iULD4B+s!7h6f&{QVPRySzIqZ%r8l#K0-FMZ29tn4FQWpB zK#l^l29t^+Cy3HeegKWYFlXHWg0Ao z=8P}4--u^9&&+sn`-)_iULD2@+s!7h6f&`_VqxT%zIqZ%rLh8w29ty$C$obBn*xId zlYl=jqXLUSjsmj=lZql2h|*Bx22l)(JRpiik#~B)WEL4_UIm`%`IA|WGjl6&O}CuF R62!u3#w4-5V+zZ!{QwH{Fna(1 diff --git a/peglib.h b/peglib.h index e2e85ec..20b546a 100644 --- a/peglib.h +++ b/peglib.h @@ -901,7 +901,6 @@ public: count++; } - auto save_error_pos = c.error_pos; while (n - i > 0 && count < max_) { c.push_capture_scope(); auto se = scope_exit([&]() { c.pop_capture_scope(); }); @@ -921,7 +920,6 @@ public: vs.tokens.erase(vs.tokens.begin() + static_cast(save_tok_size)); } - c.error_pos = save_error_pos; break; } i += len;