Changeset 24843 in webkit for trunk/JavaScriptCore/wtf/TCPageMap.h
- Timestamp:
- Aug 3, 2007, 9:21:44 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/wtf/TCPageMap.h
r24059 r24843 157 157 return true; 158 158 } 159 160 #ifdef WTF_CHANGES 161 template<class Visitor, class MemoryReader> 162 void visit(const Visitor& visitor, const MemoryReader& reader) 163 { 164 for (int i = 0; i < ROOT_LENGTH; i++) { 165 if (!root_[i]) 166 continue; 167 168 Leaf* l = reader(reinterpret_cast<Leaf*>(root_[i])); 169 for (int j = 0; j < LEAF_LENGTH; j += visitor.visit(l->values[j])) 170 ; 171 } 172 } 173 #endif 159 174 }; 160 175 … … 241 256 return true; 242 257 } 258 259 #ifdef WTF_CHANGES 260 template<class Visitor, class MemoryReader> 261 void visit(const Visitor& visitor, const MemoryReader& reader) { 262 Node* root = reader(root_); 263 for (int i = 0; i < INTERIOR_LENGTH; i++) { 264 if (!root->ptrs[i]) 265 continue; 266 267 Node* n = reader(root->ptrs[i]); 268 for (int j = 0; j < INTERIOR_LENGTH; j++) { 269 if (!n->ptrs[j]) 270 continue; 271 272 Leaf* l = reader(reinterpret_cast<Leaf*>(n->ptrs[j])); 273 for (int k = 0; k < LEAF_LENGTH; k += visitor.visit(l->values[k])) 274 ; 275 } 276 } 277 } 278 #endif 243 279 }; 244 280
Note:
See TracChangeset
for help on using the changeset viewer.