 
 			when "FunctionDeclaration"
 				vars = []
-				calls = countCalls rootNode, node, source
+				calls = countCalls rootNode, node, source, (data, timedOut) ->
+					lines = analysis.getValue().split "\n"
+					lines[data.line - 1] = lines[data.line - 1].replace "Analyzing...", (if timedOut then "TIMEOUT" else "#{data.calls} times")
+					analysisText = lines.join "\n"
+					analysis.setValue analysisText
+					console.log analysisText
+
 				# console.log(typeOf calls)
 				# console.log(calls)
 				tryEval "#{source[node.range[0]...node.range[1]]}"
 				vars.push
-					name: node.id.name + if typeOf calls is "Number" then " (#{calls} calls)" else " (#{calls})"
+					name: "(Analyzing...)"
 					type: tryEval "typeOf(#{node.id.name})"
 
 				analysisChunk = {}

	# 	console.log(error)
	# 	return -1

	tryEval modifiedCode

parse = (rootNode, source) ->
	codeAnalysis = []

							analysisChunk.line = node.expression.loc.start.line

							returnVal = tryEval "#{source[node.expression.range[0]...node.expression.range[1]]};"
							analysisChunk.raw = "-> #{JSON.stringify returnVal}: #{typeOf returnVal}"

							codeAnalysis.push analysisChunk

