[Pkg-javascript-commits] [node-acorn-jsx] 400/484: Support import and export declarations in acorn/util/walk
Bastien Roucariès
rouca at moszumanska.debian.org
Sat Aug 19 14:21:02 UTC 2017
This is an automated email from the git hooks/post-receive script.
rouca pushed a commit to branch master
in repository node-acorn-jsx.
commit 33a7c9fc24187e10299dcc0d2378dcdb93887ac7
Author: Forbes Lindesay <forbes at lindesay.co.uk>
Date: Tue Jan 13 11:10:28 2015 +0000
Support import and export declarations in acorn/util/walk
---
util/walk.js | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/util/walk.js b/util/walk.js
index 117f56f..da7ca9f 100644
--- a/util/walk.js
+++ b/util/walk.js
@@ -285,7 +285,15 @@
c(node.object, st, "Expression");
if (node.computed) c(node.property, st, "Expression");
};
- base.Identifier = base.Literal = base.ExportDeclaration = base.ImportDeclaration = ignore;
+ base.ExportDeclaration = function (node, st, c) {
+ c(node.declaration, st);
+ };
+ base.ImportDeclaration = function (node, st, c) {
+ node.specifiers.forEach(function (specifier) {
+ c(specifier, st);
+ });
+ };
+ base.ImportSpecifier = base.ImportBatchSpecifier = base.Identifier = base.Literal = ignore;
base.TaggedTemplateExpression = function(node, st, c) {
c(node.tag, st, "Expression");
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-acorn-jsx.git
More information about the Pkg-javascript-commits
mailing list