Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(325)

Side by Side Diff: Source/devtools/front_end/JSHeapSnapshot.js

Issue 206393004: Remove HeapSnapshotItemIterator.rewind (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/devtools/front_end/HeapSnapshot.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 var edge = iter.edge; 134 var edge = iter.edge;
135 if (!edge.isShortcut()) 135 if (!edge.isShortcut())
136 continue; 136 continue;
137 var node = edge.node(); 137 var node = edge.node();
138 var propNames = {}; 138 var propNames = {};
139 for (var innerIter = node.edges(); innerIter.hasNext(); innerIter.ne xt()) { 139 for (var innerIter = node.edges(); innerIter.hasNext(); innerIter.ne xt()) {
140 var globalObjEdge = innerIter.edge; 140 var globalObjEdge = innerIter.edge;
141 if (globalObjEdge.isShortcut()) 141 if (globalObjEdge.isShortcut())
142 propNames[globalObjEdge._nameOrIndex()] = true; 142 propNames[globalObjEdge._nameOrIndex()] = true;
143 } 143 }
144 for (innerIter.rewind(); innerIter.hasNext(); innerIter.next()) { 144 for (var innerIter = node.edges(); innerIter.hasNext(); innerIter.ne xt()) {
loislo 2014/03/20 13:16:40 The change is fine but looks like the code doesn't
yurys 2014/03/20 13:19:04 Yeah, I agree, let's remove it in a separate CL.
145 var globalObjEdge = innerIter.edge; 145 var globalObjEdge = innerIter.edge;
146 if (!globalObjEdge.isShortcut() 146 if (!globalObjEdge.isShortcut()
147 && globalObjEdge.node().isHidden() 147 && globalObjEdge.node().isHidden()
148 && globalObjEdge._hasStringName() 148 && globalObjEdge._hasStringName()
149 && (globalObjEdge._nameOrIndex() in propNames)) 149 && (globalObjEdge._nameOrIndex() in propNames))
150 globalObjEdge._edges[globalObjEdge.edgeIndex + this._edgeTyp eOffset] = this._edgeInvisibleType; 150 globalObjEdge._edges[globalObjEdge.edgeIndex + this._edgeTyp eOffset] = this._edgeInvisibleType;
151 } 151 }
152 } 152 }
153 }, 153 },
154 154
(...skipping 702 matching lines...) Expand 10 before | Expand all | Expand 10 after
857 * @return {boolean} 857 * @return {boolean}
858 */ 858 */
859 isWeak: function() 859 isWeak: function()
860 { 860 {
861 return this._edge().isWeak(); 861 return this._edge().isWeak();
862 }, 862 },
863 863
864 __proto__: WebInspector.HeapSnapshotRetainerEdge.prototype 864 __proto__: WebInspector.HeapSnapshotRetainerEdge.prototype
865 } 865 }
866 866
OLDNEW
« no previous file with comments | « Source/devtools/front_end/HeapSnapshot.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698