Fix two-phase lookup problem in FlexibleBodyVisitor and FixedBodyVisitor.
In FlexibleBodyVisitor and FixedBodyVisitor, the calls to IteratePointers, which lives in the base class BodyVisitorBase<StaticVisitor>, needs to be qualified with the dependent base class to be able to be bound during two-phase lookup. Review URL: http://codereview.chromium.org/3119026 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5303 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
40788b57c9
commit
2f76132ae8
@ -199,14 +199,16 @@ class FlexibleBodyVisitor : public BodyVisitorBase<StaticVisitor> {
|
||||
public:
|
||||
static inline ReturnType Visit(Map* map, HeapObject* object) {
|
||||
int object_size = BodyDescriptor::SizeOf(map, object);
|
||||
IteratePointers(object, BodyDescriptor::kStartOffset, object_size);
|
||||
BodyVisitorBase<StaticVisitor>::IteratePointers(
|
||||
object, BodyDescriptor::kStartOffset, object_size);
|
||||
return static_cast<ReturnType>(object_size);
|
||||
}
|
||||
|
||||
template<int object_size>
|
||||
static inline ReturnType VisitSpecialized(Map* map, HeapObject* object) {
|
||||
ASSERT(BodyDescriptor::SizeOf(map, object) == object_size);
|
||||
IteratePointers(object, BodyDescriptor::kStartOffset, object_size);
|
||||
BodyVisitorBase<StaticVisitor>::IteratePointers(
|
||||
object, BodyDescriptor::kStartOffset, object_size);
|
||||
return static_cast<ReturnType>(object_size);
|
||||
}
|
||||
};
|
||||
@ -216,9 +218,8 @@ template<typename StaticVisitor, typename BodyDescriptor, typename ReturnType>
|
||||
class FixedBodyVisitor : public BodyVisitorBase<StaticVisitor> {
|
||||
public:
|
||||
static inline ReturnType Visit(Map* map, HeapObject* object) {
|
||||
IteratePointers(object,
|
||||
BodyDescriptor::kStartOffset,
|
||||
BodyDescriptor::kEndOffset);
|
||||
BodyVisitorBase<StaticVisitor>::IteratePointers(
|
||||
object, BodyDescriptor::kStartOffset, BodyDescriptor::kEndOffset);
|
||||
return static_cast<ReturnType>(BodyDescriptor::kSize);
|
||||
}
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user