OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "platform/heap/CallbackStack.h" | 5 #include "platform/heap/CallbackStack.h" |
6 #include "wtf/PtrUtil.h" | 6 #include "wtf/PtrUtil.h" |
| 7 #include "wtf/StdLibExtras.h" |
7 #include "wtf/allocator/Partitions.h" | 8 #include "wtf/allocator/Partitions.h" |
8 | 9 |
9 namespace blink { | 10 namespace blink { |
10 | 11 |
11 CallbackStackMemoryPool& CallbackStackMemoryPool::instance() { | 12 CallbackStackMemoryPool& CallbackStackMemoryPool::instance() { |
12 DEFINE_STATIC_LOCAL(CallbackStackMemoryPool, memoryPool, ()); | 13 DEFINE_STATIC_LOCAL(CallbackStackMemoryPool, memoryPool, ()); |
13 return memoryPool; | 14 return memoryPool; |
14 } | 15 } |
15 | 16 |
16 void CallbackStackMemoryPool::initialize() { | 17 void CallbackStackMemoryPool::initialize() { |
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 bool CallbackStack::hasCallbackForObject(const void* object) { | 203 bool CallbackStack::hasCallbackForObject(const void* object) { |
203 for (Block* current = m_first; current; current = current->next()) { | 204 for (Block* current = m_first; current; current = current->next()) { |
204 if (current->hasCallbackForObject(object)) | 205 if (current->hasCallbackForObject(object)) |
205 return true; | 206 return true; |
206 } | 207 } |
207 return false; | 208 return false; |
208 } | 209 } |
209 #endif | 210 #endif |
210 | 211 |
211 } // namespace blink | 212 } // namespace blink |
OLD | NEW |