From 1ba592ce64eed9c941bebb0ec014e7c71c3b4708 Mon Sep 17 00:00:00 2001 From: Benoit Giannangeli Date: Mon, 29 May 2017 00:15:41 +0200 Subject: lstrlib.js: pattern index treated as pattern itself --- src/lstrlib.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/lstrlib.js b/src/lstrlib.js index 8e8b58e..c0dc2d2 100644 --- a/src/lstrlib.js +++ b/src/lstrlib.js @@ -1029,7 +1029,7 @@ const match = function(ms, s, p) { case 'b'.charCodeAt(0): { /* balanced string? */ s = matchbalance(ms, s, p + 2); if (s !== null) { - p = p.slice(4); + p += 4; gotoinit = true; } break; -- cgit v1.2.3-70-g09d2