Add ObjectVisitor template parameter to RelocInfo::Visit

This makes IterateBodyFast work without requiring visitors to inherit from ObjectVisitor.

R=ishell@chromium.org

Review URL: https://codereview.chromium.org/1900843002

Cr-Commit-Position: refs/heads/master@{#35604}
This commit is contained in:
mlippautz 2016-04-19 00:06:37 -07:00 committed by Commit bot
parent ce3f9afaba
commit 19c1a10ba0
10 changed files with 11 additions and 8 deletions

View File

@ -276,7 +276,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -868,7 +868,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -631,6 +631,8 @@ class RelocInfo {
INLINE(void WipeOut()); INLINE(void WipeOut());
template<typename StaticVisitor> inline void Visit(Heap* heap); template<typename StaticVisitor> inline void Visit(Heap* heap);
template <typename ObjectVisitor>
inline void Visit(Isolate* isolate, ObjectVisitor* v); inline void Visit(Isolate* isolate, ObjectVisitor* v);
// Check whether this debug break slot has been patched with a call to the // Check whether this debug break slot has been patched with a call to the

View File

@ -283,7 +283,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -380,7 +380,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -362,7 +362,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -343,7 +343,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -312,6 +312,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -540,7 +540,7 @@ void RelocInfo::set_debug_call_address(Address target) {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {

View File

@ -284,7 +284,7 @@ void RelocInfo::WipeOut() {
} }
} }
template <typename ObjectVisitor>
void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
RelocInfo::Mode mode = rmode(); RelocInfo::Mode mode = rmode();
if (mode == RelocInfo::EMBEDDED_OBJECT) { if (mode == RelocInfo::EMBEDDED_OBJECT) {