author | Carsten "Tomcat" Book <cbook@mozilla.com> |
Tue, 28 Jan 2014 14:03:38 +0100 | |
changeset 165564 | 224fceb749a2a539580c7442474035f86730934b |
parent 165563 | a4f31914bb0c51050e98a914225db7f4ceba7caf |
child 165565 | d23cd37cc2d125208d0d1cfc4a9191b0be4245c9 |
push id | 26097 |
push user | ryanvm@gmail.com |
push date | Tue, 28 Jan 2014 21:18:27 +0000 |
treeherder | mozilla-central@128c86a925d7 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
bugs | 964700 |
milestone | 29.0a1 |
backs out | a76a4f9219876a3eeded0989d3dddd0432cd6ac9 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
browser/devtools/shared/Parser.jsm | file | annotate | diff | comparison | revisions | |
toolkit/devtools/DevToolsUtils.js | file | annotate | diff | comparison | revisions |
--- a/browser/devtools/shared/Parser.jsm +++ b/browser/devtools/shared/Parser.jsm @@ -80,17 +80,17 @@ Parser.prototype = { syntaxTrees.push(new SyntaxTree(nodes, aUrl, length, offset)); } catch (e) { this.errors.push(e); DevToolsUtils.reportException(aUrl, e); } } } - let pool = new SyntaxTreesPool(syntaxTrees, aUrl); + let pool = new SyntaxTreesPool(syntaxTrees); // Cache the syntax trees pool by the specified url. This is entirely // optional, but it's strongly encouraged to cache ASTs because // generating them can be costly with big/complex sources. if (aUrl) { this._cache.set(aUrl, pool); } @@ -118,22 +118,19 @@ Parser.prototype = { errors: null }; /** * A pool handling a collection of AST nodes generated by the reflection API. * * @param object aSyntaxTrees * A collection of AST nodes generated for a source. - * @param string aUrl [optional] - * The source url. */ -function SyntaxTreesPool(aSyntaxTrees, aUrl = "<unknown>") { +function SyntaxTreesPool(aSyntaxTrees) { this._trees = aSyntaxTrees; - this._url = aUrl; this._cache = new Map(); } SyntaxTreesPool.prototype = { /** * @see SyntaxTree.prototype.getIdentifierAt */ getIdentifierAt: function({ line, column, scriptIndex }) { @@ -213,17 +210,17 @@ SyntaxTreesPool.prototype = { parseResults.scriptLength = syntaxTree.length; parseResults.scriptOffset = syntaxTree.offset; results.push(parseResults); } } catch (e) { // Can't guarantee that the tree traversal logic is forever perfect :) // Language features may be added, in which case the recursive methods // need to be updated. If an exception is thrown here, file a bug. - DevToolsUtils.reportException("Syntax tree visitor for " + aUrl, e); + DevToolsUtils.reportException("syntax tree", e); } } this._cache.set(requestId, results); return results; }, _trees: null, _cache: null
--- a/toolkit/devtools/DevToolsUtils.js +++ b/toolkit/devtools/DevToolsUtils.js @@ -24,17 +24,17 @@ this.safeErrorString = function safeErro let stack = aError.stack.toString(); if (typeof stack == "string") { errorString += "\nStack: " + stack; } } } catch (ee) { } if (typeof aError.lineNumber == "number" && typeof aError.columnNumber == "number") { - errorString += "Line: " + aError.lineNumber + ", column: " + aError.columnNumber; + errorString += ", line: " + aError.lineNumber + ", column: " + aError.columnNumber; } return errorString; } } catch (ee) { } return "<failed trying to find error description>"; }