flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cd...@apache.org
Subject [15/50] git commit: [flex-falcon] [refs/heads/feature/maven-migration] - fixed source map for object and array literals now that all [] and {} are included in AST
Date Mon, 11 Apr 2016 13:59:42 GMT
fixed source map for object and array literals now that all [] and {} are included in AST


Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/847dc159
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/847dc159
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/847dc159

Branch: refs/heads/feature/maven-migration
Commit: 847dc159f4921c7ffb8e65f9786900ecbece8321
Parents: ea51f07
Author: Josh Tynjala <joshtynjala@apache.org>
Authored: Wed Mar 30 16:33:23 2016 -0700
Committer: Josh Tynjala <joshtynjala@apache.org>
Committed: Wed Mar 30 16:33:23 2016 -0700

----------------------------------------------------------------------
 .../org/apache/flex/compiler/internal/codegen/js/JSEmitter.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/847dc159/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/JSEmitter.java
----------------------------------------------------------------------
diff --git a/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/JSEmitter.java b/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/JSEmitter.java
index aae2cfd..e42056c 100644
--- a/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/JSEmitter.java
+++ b/compiler.jx/src/org/apache/flex/compiler/internal/codegen/js/JSEmitter.java
@@ -236,7 +236,7 @@ public class JSEmitter extends ASEmitter implements IJSEmitter
                 //we're mapping the comma to the literal container, but we use
                 //the child line/column in case the comma is not on the same
                 //line as the opening { or [
-                startMapping(node, child.getLine(), child.getColumn() + child.getEnd() -
child.getStart());
+                startMapping(node, child.getLine(), child.getColumn() + child.getAbsoluteEnd()
- child.getAbsoluteStart());
                 writeToken(ASEmitterTokens.COMMA);
                 endMapping(node);
             }
@@ -244,7 +244,7 @@ public class JSEmitter extends ASEmitter implements IJSEmitter
 
         if (postFix != null)
         {
-            startMapping(node, node.getAbsoluteEnd() - node.getAbsoluteStart());
+            startMapping(node, node.getAbsoluteEnd() - node.getAbsoluteStart() - 1);
             write(postFix);
             endMapping(node);
         }


Mime
View raw message