|
@ -585,6 +585,7 @@ enum CompareResult { |
|
|
|
|
|
|
|
|
class StringStream; |
|
|
class StringStream; |
|
|
class ObjectVisitor; |
|
|
class ObjectVisitor; |
|
|
|
|
|
class Failure; |
|
|
|
|
|
|
|
|
struct ValueInfo : public Malloced { |
|
|
struct ValueInfo : public Malloced { |
|
|
ValueInfo() : type(FIRST_TYPE), ptr(NULL), str(NULL), number(0) { } |
|
|
ValueInfo() : type(FIRST_TYPE), ptr(NULL), str(NULL), number(0) { } |
|
@ -611,6 +612,10 @@ class MaybeObject BASE_EMBEDDED { |
|
|
*obj = reinterpret_cast<Object*>(this); |
|
|
*obj = reinterpret_cast<Object*>(this); |
|
|
return true; |
|
|
return true; |
|
|
} |
|
|
} |
|
|
|
|
|
inline Failure* ToFailureUnchecked() { |
|
|
|
|
|
ASSERT(IsFailure()); |
|
|
|
|
|
return reinterpret_cast<Failure*>(this); |
|
|
|
|
|
} |
|
|
inline Object* ToObjectUnchecked() { |
|
|
inline Object* ToObjectUnchecked() { |
|
|
ASSERT(!IsFailure()); |
|
|
ASSERT(!IsFailure()); |
|
|
return reinterpret_cast<Object*>(this); |
|
|
return reinterpret_cast<Object*>(this); |
|
|