aboutsummaryrefslogtreecommitdiff
path: root/lib/mozilla-ast.js
diff options
context:
space:
mode:
authorMihai Bazon <mihai@bazon.net>2012-10-13 11:37:58 +0300
committerMihai Bazon <mihai@bazon.net>2012-10-13 11:37:58 +0300
commitb51fe0dcc348fe2c3942b04c7c7d88f3fb7eaa49 (patch)
tree68779bec44d50563b49c81b5ef647ef1664b4a72 /lib/mozilla-ast.js
parent70d205c447c05d053c953659d3ddc41759e37579 (diff)
downloadtracifyjs-b51fe0dcc348fe2c3942b04c7c7d88f3fb7eaa49.tar.gz
tracifyjs-b51fe0dcc348fe2c3942b04c7c7d88f3fb7eaa49.zip
fix end tokens in spidermonkey ast import
Diffstat (limited to 'lib/mozilla-ast.js')
-rw-r--r--lib/mozilla-ast.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/mozilla-ast.js b/lib/mozilla-ast.js
index 4db8feff..982d621a 100644
--- a/lib/mozilla-ast.js
+++ b/lib/mozilla-ast.js
@@ -58,7 +58,7 @@
CatchClause : function(M) {
return new AST_Catch({
start : my_start_token(M),
- end : my_start_token(M),
+ end : my_end_token(M),
argname : from_moz(M.param),
body : from_moz(M.body).body
});
@@ -95,7 +95,7 @@
MemberExpression : function(M) {
return new (M.computed ? AST_Sub : AST_Dot)({
start : my_start_token(M),
- end : my_start_token(M),
+ end : my_end_token(M),
property : M.computed ? from_moz(M.property) : M.property.name,
expression : from_moz(M.object)
});
@@ -103,7 +103,7 @@
SwitchCase : function(M) {
return new (M.test ? AST_Case : AST_Default)({
start : my_start_token(M),
- end : my_start_token(M),
+ end : my_end_token(M),
expression : from_moz(M.test),
body : M.consequent.map(from_moz)
});