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

Side by Side Diff: tools/clang/blink_gc_plugin/RecordInfo.h

Issue 1158623002: Extend destructor checks to account for eagerly finalized class types. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: updated to look for IsEagerlyFinalizedMarker instead Created 5 years, 7 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
« no previous file with comments | « tools/clang/blink_gc_plugin/Config.h ('k') | tools/clang/blink_gc_plugin/RecordInfo.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // This file provides a wrapper for CXXRecordDecl that accumulates GC related 5 // This file provides a wrapper for CXXRecordDecl that accumulates GC related
6 // information about a class. Accumulated information is memoized and the info 6 // information about a class. Accumulated information is memoized and the info
7 // objects are stored in a RecordCache. 7 // objects are stored in a RecordCache.
8 8
9 #ifndef TOOLS_BLINK_GC_PLUGIN_RECORD_INFO_H_ 9 #ifndef TOOLS_BLINK_GC_PLUGIN_RECORD_INFO_H_
10 #define TOOLS_BLINK_GC_PLUGIN_RECORD_INFO_H_ 10 #define TOOLS_BLINK_GC_PLUGIN_RECORD_INFO_H_
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 87
88 bool IsHeapAllocatedCollection(); 88 bool IsHeapAllocatedCollection();
89 bool IsGCDerived(); 89 bool IsGCDerived();
90 bool IsGCAllocated(); 90 bool IsGCAllocated();
91 bool IsGCFinalized(); 91 bool IsGCFinalized();
92 bool IsGCMixin(); 92 bool IsGCMixin();
93 bool IsStackAllocated(); 93 bool IsStackAllocated();
94 bool IsNonNewable(); 94 bool IsNonNewable();
95 bool IsOnlyPlacementNewable(); 95 bool IsOnlyPlacementNewable();
96 bool IsGCMixinInstance(); 96 bool IsGCMixinInstance();
97 bool IsEagerlyFinalized();
98
97 clang::CXXMethodDecl* DeclaresNewOperator(); 99 clang::CXXMethodDecl* DeclaresNewOperator();
98 100
99 bool RequiresTraceMethod(); 101 bool RequiresTraceMethod();
100 bool NeedsFinalization(); 102 bool NeedsFinalization();
101 bool DeclaresGCMixinMethods(); 103 bool DeclaresGCMixinMethods();
102 bool DeclaresLocalTraceMethod(); 104 bool DeclaresLocalTraceMethod();
103 TracingStatus NeedsTracing(Edge::NeedsTracingOption); 105 TracingStatus NeedsTracing(Edge::NeedsTracingOption);
104 clang::CXXMethodDecl* InheritsNonVirtualTrace(); 106 clang::CXXMethodDecl* InheritsNonVirtualTrace();
105 bool IsConsideredAbstract(); 107 bool IsConsideredAbstract();
106 108
(...skipping 18 matching lines...) Expand all
125 Bases* bases_; 127 Bases* bases_;
126 Fields* fields_; 128 Fields* fields_;
127 129
128 enum CachedBool { kFalse = 0, kTrue = 1, kNotComputed = 2 }; 130 enum CachedBool { kFalse = 0, kTrue = 1, kNotComputed = 2 };
129 CachedBool is_stack_allocated_; 131 CachedBool is_stack_allocated_;
130 CachedBool is_non_newable_; 132 CachedBool is_non_newable_;
131 CachedBool is_only_placement_newable_; 133 CachedBool is_only_placement_newable_;
132 CachedBool does_need_finalization_; 134 CachedBool does_need_finalization_;
133 CachedBool has_gc_mixin_methods_; 135 CachedBool has_gc_mixin_methods_;
134 CachedBool is_declaring_local_trace_; 136 CachedBool is_declaring_local_trace_;
137 CachedBool is_eagerly_finalized_;
135 138
136 bool determined_trace_methods_; 139 bool determined_trace_methods_;
137 clang::CXXMethodDecl* trace_method_; 140 clang::CXXMethodDecl* trace_method_;
138 clang::CXXMethodDecl* trace_dispatch_method_; 141 clang::CXXMethodDecl* trace_dispatch_method_;
139 clang::CXXMethodDecl* finalize_dispatch_method_; 142 clang::CXXMethodDecl* finalize_dispatch_method_;
140 143
141 bool is_gc_derived_; 144 bool is_gc_derived_;
142 145
143 std::vector<std::string> gc_base_names_; 146 std::vector<std::string> gc_base_names_;
144 147
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 } 179 }
177 } 180 }
178 } 181 }
179 182
180 private: 183 private:
181 typedef std::map<clang::CXXRecordDecl*, RecordInfo> Cache; 184 typedef std::map<clang::CXXRecordDecl*, RecordInfo> Cache;
182 Cache cache_; 185 Cache cache_;
183 }; 186 };
184 187
185 #endif // TOOLS_BLINK_GC_PLUGIN_RECORD_INFO_H_ 188 #endif // TOOLS_BLINK_GC_PLUGIN_RECORD_INFO_H_
OLDNEW
« no previous file with comments | « tools/clang/blink_gc_plugin/Config.h ('k') | tools/clang/blink_gc_plugin/RecordInfo.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698