Commit b8bcfeff authored by yann300's avatar yann300

createReducedTrace

parent 00cc6a23
...@@ -36,7 +36,7 @@ class InternalCallTree { ...@@ -36,7 +36,7 @@ class InternalCallTree {
this.event.trigger('callTreeBuildFailed', [result.error]) this.event.trigger('callTreeBuildFailed', [result.error])
} else { } else {
console.log('ready') console.log('ready')
this.reducedTrace.push(traceManager.trace.length - 1) createReducedTrace(this, traceManager.trace.length - 1)
this.event.trigger('callTreeReady', [this.scopes, this.scopeStarts]) this.event.trigger('callTreeReady', [this.scopes, this.scopeStarts])
} }
}) })
...@@ -130,6 +130,10 @@ async function buildTree (tree, step, scopeId) { ...@@ -130,6 +130,10 @@ async function buildTree (tree, step, scopeId) {
return { outStep: step } return { outStep: step }
} }
function createReducedTrace (tree, index) {
tree.reducedTrace.push(index)
}
function includeVariableDeclaration (tree, step, sourceLocation, scopeId) { function includeVariableDeclaration (tree, step, sourceLocation, scopeId) {
var variableDeclaration = resolveVariableDeclaration(tree, step, sourceLocation) var variableDeclaration = resolveVariableDeclaration(tree, step, sourceLocation)
if (variableDeclaration && !tree.scopes[scopeId].locals[variableDeclaration.attributes.name]) { if (variableDeclaration && !tree.scopes[scopeId].locals[variableDeclaration.attributes.name]) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment