Index: tools/clang/blink_gc_plugin/RecordInfo.cpp |
diff --git a/tools/clang/blink_gc_plugin/RecordInfo.cpp b/tools/clang/blink_gc_plugin/RecordInfo.cpp |
index 516a40a04daec50f420e1262ef2cff2d4a349202..cf7fb8c578e80ed3e4b6c1f78e83260e1848dda2 100644 |
--- a/tools/clang/blink_gc_plugin/RecordInfo.cpp |
+++ b/tools/clang/blink_gc_plugin/RecordInfo.cpp |
@@ -186,6 +186,16 @@ bool RecordInfo::IsEagerlyFinalized() { |
return is_eagerly_finalized_; |
} |
+bool RecordInfo::IsGCRefCounted() { |
+ if (!IsGCDerived()) |
+ return false; |
+ for (const auto& gc_base : gc_base_names_) { |
+ if (Config::IsGCRefCountedBase(gc_base)) |
+ return true; |
+ } |
+ return false; |
+} |
+ |
bool RecordInfo::HasDefinition() { |
return record_->hasDefinition(); |
} |