| OLD | NEW |
| 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 } | 167 } |
| 168 | 168 |
| 169 // We have a trace method in the SupplementableBase class to ensure we have | 169 // We have a trace method in the SupplementableBase class to ensure we have |
| 170 // the vtable at the first word of the object. However we don't trace the | 170 // the vtable at the first word of the object. However we don't trace the |
| 171 // m_supplements here, but in the partially specialized template subclasses | 171 // m_supplements here, but in the partially specialized template subclasses |
| 172 // since we only want to trace it for garbage collected classes. | 172 // since we only want to trace it for garbage collected classes. |
| 173 virtual void trace(Visitor*) { } | 173 virtual void trace(Visitor*) { } |
| 174 | 174 |
| 175 // FIXME: Oilpan: Make private and remove this ignore once PersistentHeapSup
plementable is removed again. | 175 // FIXME: Oilpan: Make private and remove this ignore once PersistentHeapSup
plementable is removed again. |
| 176 protected: | 176 protected: |
| 177 GC_PLUGIN_IGNORE("") | |
| 178 typename SupplementableTraits<T, isGarbageCollected>::SupplementMap m_supple
ments; | 177 typename SupplementableTraits<T, isGarbageCollected>::SupplementMap m_supple
ments; |
| 179 | 178 |
| 180 #if ENABLE(ASSERT) | 179 #if ENABLE(ASSERT) |
| 181 protected: | 180 protected: |
| 182 SupplementableBase() : m_threadId(currentThread()) { } | 181 SupplementableBase() : m_threadId(currentThread()) { } |
| 183 | 182 |
| 184 private: | 183 private: |
| 185 ThreadIdentifier m_threadId; | 184 ThreadIdentifier m_threadId; |
| 186 #endif | 185 #endif |
| 187 }; | 186 }; |
| 188 | 187 |
| 189 | 188 |
| 190 template<typename T> | 189 template<typename T> |
| 191 class Supplement : public SupplementBase<T, false> { }; | 190 class Supplement : public SupplementBase<T, false> { }; |
| 192 | 191 |
| 193 // This class is used to make an off-heap class supplementable with off-heap | 192 // This class is used to make an off-heap class supplementable with off-heap |
| 194 // supplements (Supplement). | 193 // supplements (Supplement). |
| 195 template<typename T> | 194 template<typename T> |
| 196 class GC_PLUGIN_IGNORE("http://crbug.com/395036") Supplementable : public Supple
mentableBase<T, false> { | 195 class Supplementable : public SupplementableBase<T, false> { |
| 197 }; | 196 }; |
| 198 | 197 |
| 199 } // namespace blink | 198 } // namespace blink |
| 200 | 199 |
| 201 #endif // Supplementable_h | 200 #endif // Supplementable_h |
| OLD | NEW |