Commit d95f82e6 authored by Clemens Hammacher's avatar Clemens Hammacher Committed by Commit Bot

[cleanup] Remove {operator->} on Object and subtypes

For consistency, {Object} members should only be accessed via ".".
CL https://crrev.com/c/1624209 cleaned up the code base already. This
CL removes the now dead operator.

R=jkummerow@chromium.org

Bug: v8:9183, v8:3770
Change-Id: I599dcd49d79bfc68f970fe872b64b3b2680cddd5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1624788
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61768}
parent 7b12e3b9
......@@ -3238,7 +3238,7 @@ void Simulator::Debug() {
Object obj(value);
os << arg1 << ": \n";
#ifdef DEBUG
obj->Print(os);
obj.Print(os);
os << "\n";
#else
os << Brief(obj) << "\n";
......
......@@ -273,10 +273,6 @@ class Object : public TaggedImpl<HeapObjectReferenceType::STRONG, Address> {
constexpr Object() : TaggedImpl(kNullAddress) {}
explicit constexpr Object(Address ptr) : TaggedImpl(ptr) {}
// These operator->() overloads are required for handlified code.
Object* operator->() { return this; }
const Object* operator->() const { return this; }
#define IS_TYPE_FUNCTION_DECL(Type) V8_INLINE bool Is##Type() const;
OBJECT_TYPE_LIST(IS_TYPE_FUNCTION_DECL)
HEAP_OBJECT_TYPE_LIST(IS_TYPE_FUNCTION_DECL)
......
......@@ -21,8 +21,6 @@
#define OBJECT_CONSTRUCTORS(Type, ...) \
public: \
constexpr Type() : __VA_ARGS__() {} \
Type* operator->() { return this; } \
const Type* operator->() const { return this; } \
\
protected: \
explicit inline Type(Address ptr)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment