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

Side by Side Diff: tools/clang/blink_gc_plugin/Edge.cpp

Issue 2588943002: Disallow heap objects containing unsafe on-heap iterators. (Closed)
Patch Set: formatting Created 3 years, 12 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
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 #include "Config.h" 5 #include "Config.h"
6 #include "Edge.h" 6 #include "Edge.h"
7 #include "RecordInfo.h" 7 #include "RecordInfo.h"
8 8
9 TracingStatus Value::NeedsTracing(NeedsTracingOption option) { 9 TracingStatus Value::NeedsTracing(NeedsTracingOption option) {
10 return value_->NeedsTracing(option); 10 return value_->NeedsTracing(option);
11 } 11 }
12 12
13 bool Value::NeedsFinalization() { return value_->NeedsFinalization(); } 13 bool Value::NeedsFinalization() { return value_->NeedsFinalization(); }
14 bool Collection::NeedsFinalization() { return info_->NeedsFinalization(); } 14 bool Collection::NeedsFinalization() { return info_->NeedsFinalization(); }
15 15
16 void RecursiveEdgeVisitor::AtValue(Value*) {} 16 void RecursiveEdgeVisitor::AtValue(Value*) {}
17 void RecursiveEdgeVisitor::AtRawPtr(RawPtr*) {} 17 void RecursiveEdgeVisitor::AtRawPtr(RawPtr*) {}
18 void RecursiveEdgeVisitor::AtRefPtr(RefPtr*) {} 18 void RecursiveEdgeVisitor::AtRefPtr(RefPtr*) {}
19 void RecursiveEdgeVisitor::AtOwnPtr(OwnPtr*) {} 19 void RecursiveEdgeVisitor::AtOwnPtr(OwnPtr*) {}
20 void RecursiveEdgeVisitor::AtUniquePtr(UniquePtr*) {} 20 void RecursiveEdgeVisitor::AtUniquePtr(UniquePtr*) {}
21 void RecursiveEdgeVisitor::AtMember(Member*) {} 21 void RecursiveEdgeVisitor::AtMember(Member*) {}
22 void RecursiveEdgeVisitor::AtWeakMember(WeakMember*) {} 22 void RecursiveEdgeVisitor::AtWeakMember(WeakMember*) {}
23 void RecursiveEdgeVisitor::AtPersistent(Persistent*) {} 23 void RecursiveEdgeVisitor::AtPersistent(Persistent*) {}
24 void RecursiveEdgeVisitor::AtCrossThreadPersistent(CrossThreadPersistent*) {} 24 void RecursiveEdgeVisitor::AtCrossThreadPersistent(CrossThreadPersistent*) {}
25 void RecursiveEdgeVisitor::AtCollection(Collection*) {} 25 void RecursiveEdgeVisitor::AtCollection(Collection*) {}
26 void RecursiveEdgeVisitor::AtIterator(Iterator*) {}
26 27
27 void RecursiveEdgeVisitor::VisitValue(Value* e) { 28 void RecursiveEdgeVisitor::VisitValue(Value* e) {
28 AtValue(e); 29 AtValue(e);
29 } 30 }
30 31
31 void RecursiveEdgeVisitor::VisitRawPtr(RawPtr* e) { 32 void RecursiveEdgeVisitor::VisitRawPtr(RawPtr* e) {
32 AtRawPtr(e); 33 AtRawPtr(e);
33 Enter(e); 34 Enter(e);
34 e->ptr()->Accept(this); 35 e->ptr()->Accept(this);
35 Leave(); 36 Leave();
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 e->ptr()->Accept(this); 84 e->ptr()->Accept(this);
84 Leave(); 85 Leave();
85 } 86 }
86 87
87 void RecursiveEdgeVisitor::VisitCollection(Collection* e) { 88 void RecursiveEdgeVisitor::VisitCollection(Collection* e) {
88 AtCollection(e); 89 AtCollection(e);
89 Enter(e); 90 Enter(e);
90 e->AcceptMembers(this); 91 e->AcceptMembers(this);
91 Leave(); 92 Leave();
92 } 93 }
94
95 void RecursiveEdgeVisitor::VisitIterator(Iterator* e) {
96 AtIterator(e);
97 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698