flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From joshtynj...@apache.org
Subject [2/2] git commit: [flex-falcon] [refs/heads/feature/debugger-statement] - FLEX-35343 debugger statement in AS generates call to flash.debugger.enterDebugger() in SWF
Date Fri, 21 Jul 2017 23:37:37 GMT
FLEX-35343 debugger statement in AS generates call to flash.debugger.enterDebugger() in SWF


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

Branch: refs/heads/feature/debugger-statement
Commit: 427d95c5643f0240974a5650bdf6669194c4bd74
Parents: d4a3807
Author: Josh Tynjala <joshtynjala@apache.org>
Authored: Fri Jul 21 16:37:18 2017 -0700
Committer: Josh Tynjala <joshtynjala@apache.org>
Committed: Fri Jul 21 16:37:18 2017 -0700

----------------------------------------------------------------------
 .../internal/as/codegen/ABCGeneratingReducer.java         | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/427d95c5/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
----------------------------------------------------------------------
diff --git a/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
b/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
index 359d32d..4e3d169 100644
--- a/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
+++ b/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
@@ -3224,8 +3224,14 @@ public class ABCGeneratingReducer
 
     public InstructionList reduce_debuggerStmt(IASNode iNode)
     {
-        //TODO: make runtime pause in debugger -JT
-        return createInstructionList(iNode);
+        InstructionList result = createInstructionList(iNode);
+
+        Namespace ns = new Namespace(CONSTANT_PackageNs, "flash.debugger");
+        Name enterDebuggerName = new Name(ns, "enterDebugger");
+        result.addInstruction(OP_finddef, enterDebuggerName);
+        result.addInstruction(OP_callproperty, new Object[] {enterDebuggerName, 0});
+
+        return result;
     }
 
     public InstructionList reduce_breakStmt(IASNode iNode)


Mime
View raw message