From b3efd45f2a7737e1460989cd66711bd3d42d650e Mon Sep 17 00:00:00 2001 From: marihachi Date: Sun, 9 Jan 2022 22:55:55 +0900 Subject: [PATCH] fix opts of internal parsing --- src/internal/parser.pegjs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/internal/parser.pegjs b/src/internal/parser.pegjs index 1de7b9b..57de314 100644 --- a/src/internal/parser.pegjs +++ b/src/internal/parser.pegjs @@ -32,7 +32,11 @@ function applyParser(input, startRule, opts) { const parseFunc = peg$parse; - const parseOpts = { ...(opts || {}) }; + const parseOpts = { + fnNameList: options.fnNameList, + nestLimit: (nestLimit - depth), + ...(opts || {}), + }; if (startRule) parseOpts.startRule = startRule; return parseFunc(input, parseOpts); }