Title: [119839] trunk/Source/WebCore
- Revision
- 119839
- Author
- [email protected]
- Date
- 2012-06-08 09:57:08 -0700 (Fri, 08 Jun 2012)
Log Message
Web Inspector: Fix several compiler warnings and errors.
https://bugs.webkit.org/show_bug.cgi?id=88660
Reviewed by Pavel Feldman.
Fixed several compiler warnings and errors.
Removed isEmpty method from Object.prototype and made it static method on Object.
* inspector/InjectedScriptExterns.js:
* inspector/front-end/FileSystemModel.js:
(WebInspector.FileSystemModel.prototype._detachFrame):
* inspector/front-end/HeapSnapshot.js:
(WebInspector.HeapSnapshot.prototype._buildDominatorTree):
* inspector/front-end/utilities.js:
(Object.isEmpty):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (119838 => 119839)
--- trunk/Source/WebCore/ChangeLog 2012-06-08 16:54:24 UTC (rev 119838)
+++ trunk/Source/WebCore/ChangeLog 2012-06-08 16:57:08 UTC (rev 119839)
@@ -1,3 +1,21 @@
+2012-06-08 Vsevolod Vlasov <[email protected]>
+
+ Web Inspector: Fix several compiler warnings and errors.
+ https://bugs.webkit.org/show_bug.cgi?id=88660
+
+ Reviewed by Pavel Feldman.
+
+ Fixed several compiler warnings and errors.
+ Removed isEmpty method from Object.prototype and made it static method on Object.
+
+ * inspector/InjectedScriptExterns.js:
+ * inspector/front-end/FileSystemModel.js:
+ (WebInspector.FileSystemModel.prototype._detachFrame):
+ * inspector/front-end/HeapSnapshot.js:
+ (WebInspector.HeapSnapshot.prototype._buildDominatorTree):
+ * inspector/front-end/utilities.js:
+ (Object.isEmpty):
+
2012-06-08 Max Feil <[email protected]>
[BlackBerry] Fix assertion failure introduced by bug 87551
Modified: trunk/Source/WebCore/inspector/InjectedScriptExterns.js (119838 => 119839)
--- trunk/Source/WebCore/inspector/InjectedScriptExterns.js 2012-06-08 16:54:24 UTC (rev 119838)
+++ trunk/Source/WebCore/inspector/InjectedScriptExterns.js 2012-06-08 16:57:08 UTC (rev 119839)
@@ -98,5 +98,13 @@
*/
_javascript_CallFrame.prototype.scopeType = function(index) { }
+/**
+ * @constructor
+ */
+function _javascript_Function()
+{
+ /** @type {Array} */
+ this.rawScopes;
+}
var InspectorBackend = { };
Modified: trunk/Source/WebCore/inspector/front-end/FileSystemModel.js (119838 => 119839)
--- trunk/Source/WebCore/inspector/front-end/FileSystemModel.js 2012-06-08 16:54:24 UTC (rev 119838)
+++ trunk/Source/WebCore/inspector/front-end/FileSystemModel.js 2012-06-08 16:57:08 UTC (rev 119839)
@@ -124,7 +124,7 @@
delete this._originForFrameId[frame.id];
delete this._frameIdsForOrigin[origin][frame.id];
- var lastOrigin = this._frameIdsForOrigin[origin].isEmpty();
+ var lastOrigin = Object.isEmpty(this._frameIdsForOrigin[origin]);
if (lastOrigin) {
delete this._frameIdsForOrigin[origin];
this._originRemoved(origin);
Modified: trunk/Source/WebCore/inspector/front-end/HeapSnapshot.js (119838 => 119839)
--- trunk/Source/WebCore/inspector/front-end/HeapSnapshot.js 2012-06-08 16:54:24 UTC (rev 119838)
+++ trunk/Source/WebCore/inspector/front-end/HeapSnapshot.js 2012-06-08 16:57:08 UTC (rev 119839)
@@ -1188,9 +1188,10 @@
// The affected array is used to mark entries which dominators
// have to be racalculated because of changes in their retainers.
var affected = new Uint8Array(nodesCount);
+ var nodeOrdinal;
{ // Mark the root direct children as affected.
- var nodeOrdinal = this._rootNodeIndex / nodeFieldCount;
+ nodeOrdinal = this._rootNodeIndex / nodeFieldCount;
var beginEdgeToNodeFieldIndex = firstEdgeIndexes[nodeOrdinal] + edgeToNodeOffset;
var endEdgeToNodeFieldIndex = firstEdgeIndexes[nodeOrdinal + 1];
for (var toNodeFieldIndex = beginEdgeToNodeFieldIndex;
@@ -1212,7 +1213,7 @@
// then it can't propagate any further.
if (dominators[postOrderIndex] === rootPostOrderedIndex)
continue;
- var nodeOrdinal = postOrderIndex2NodeOrdinal[postOrderIndex];
+ nodeOrdinal = postOrderIndex2NodeOrdinal[postOrderIndex];
var nodeFlag = !!(flags[nodeOrdinal] & flag);
var newDominatorIndex = noEntry;
var beginRetainerIndex = firstRetainerIndex[nodeOrdinal];
@@ -1265,7 +1266,7 @@
var dominatorsTree = new Uint32Array(nodesCount);
for (var postOrderIndex = 0, l = dominators.length; postOrderIndex < l; ++postOrderIndex) {
- var nodeOrdinal = postOrderIndex2NodeOrdinal[postOrderIndex];
+ nodeOrdinal = postOrderIndex2NodeOrdinal[postOrderIndex];
dominatorsTree[nodeOrdinal] = postOrderIndex2NodeOrdinal[dominators[postOrderIndex]];
}
return dominatorsTree;
Modified: trunk/Source/WebCore/inspector/front-end/utilities.js (119838 => 119839)
--- trunk/Source/WebCore/inspector/front-end/utilities.js 2012-06-08 16:54:24 UTC (rev 119838)
+++ trunk/Source/WebCore/inspector/front-end/utilities.js 2012-06-08 16:57:08 UTC (rev 119839)
@@ -27,6 +27,13 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+Object.isEmpty = function(obj)
+{
+ for (var i in obj)
+ return false;
+ return true;
+}
+
String.prototype.hasSubstring = function(string, caseInsensitive)
{
if (!caseInsensitive)
@@ -676,13 +683,3 @@
this._map = {};
}
};
-
-Object.defineProperty(Object.prototype, "isEmpty",
-{
- value: function()
- {
- for (var i in this)
- return false;
- return true;
- }
-});
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes