aboutsummaryrefslogtreecommitdiff
path: root/lib/parse.js
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2020-12-19 12:28:38 +0800
committerGitHub <noreply@github.com>2020-12-19 12:28:38 +0800
commite6dd471f8fff84c878153008139150a090c5ba19 (patch)
treeec207ca4b7416a79b9abba17fdda35b44e5ef743 /lib/parse.js
parent0f55bd92f18bd27628f1cfd10c9fb5d70f4d4d29 (diff)
downloadtracifyjs-e6dd471f8fff84c878153008139150a090c5ba19.tar.gz
tracifyjs-e6dd471f8fff84c878153008139150a090c5ba19.zip
support destructuring of `catch` variable (#4412)
Diffstat (limited to 'lib/parse.js')
-rw-r--r--lib/parse.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/parse.js b/lib/parse.js
index f760d0de..3b7d15ca 100644
--- a/lib/parse.js
+++ b/lib/parse.js
@@ -1216,7 +1216,7 @@ function parse($TEXT, options) {
var name = null;
if (is("punc", "(")) {
next();
- name = as_symbol(AST_SymbolCatch);
+ name = maybe_destructured(AST_SymbolCatch);
expect(")");
}
bcatch = new AST_Catch({