1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef DESTRUCTOR_EAGERLY_FINALIZED_H_
6 #define DESTRUCTOR_EAGERLY_FINALIZED_H_
8 #include "heap/stubs.h"
12 class HeapObject
: public GarbageCollected
<HeapObject
> {
14 void trace(Visitor
*) { }
18 class HeapObjectEagerFinalized
19 : public GarbageCollectedFinalized
<HeapObjectEagerFinalized
> {
22 ~HeapObjectEagerFinalized();
28 Member
<HeapObject
> m_obj
;
31 // Accessing other eagerly finalized objects during finalization is not allowed.
32 class HeapObjectEagerFinalizedAlso
33 : public GarbageCollectedFinalized
<HeapObjectEagerFinalizedAlso
> {
36 ~HeapObjectEagerFinalizedAlso();
40 Member
<HeapObject
> m_heapObject
;
41 Member
<HeapObjectEagerFinalized
> m_heapObjectFinalized
;
42 HeapVector
<Member
<HeapObjectEagerFinalized
>> m_heapVector
;
47 #endif // DESTRUCTOR_EAGERLY_FINALIZED_H_