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

Unified Diff: src/objects.h

Issue 252383006: NameDictionary's key type is now Handle<Name> instead of Name*. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 37eb1393ff2b13f4ca3dc19bed21669b79fead40..5f695db4eebc7f0c7f4752b86bf16c7fb9565560 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -4119,14 +4119,14 @@ class Dictionary: public HashTable<Derived, Shape, Key> {
};
-class NameDictionaryShape : public BaseShape<Name*> {
+class NameDictionaryShape : public BaseShape<Handle<Name> > {
public:
- static inline bool IsMatch(Name* key, Object* other);
- static inline uint32_t Hash(Name* key);
- static inline uint32_t HashForObject(Name* key, Object* object);
+ static inline bool IsMatch(Handle<Name> key, Object* other);
+ static inline uint32_t Hash(Handle<Name> key);
+ static inline uint32_t HashForObject(Handle<Name> key, Object* object);
MUST_USE_RESULT static inline MaybeObject* AsObject(Heap* heap,
- Name* key);
- static inline Handle<Object> AsHandle(Isolate* isolate, Name* key);
+ Handle<Name> key);
+ static inline Handle<Object> AsHandle(Isolate* isolate, Handle<Name> key);
static const int kPrefixSize = 2;
static const int kEntrySize = 3;
static const bool kIsEnumerable = true;
@@ -4135,7 +4135,7 @@ class NameDictionaryShape : public BaseShape<Name*> {
class NameDictionary: public Dictionary<NameDictionary,
NameDictionaryShape,
- Name*> {
+ Handle<Name> > {
public:
static inline NameDictionary* cast(Object* obj) {
ASSERT(obj->IsDictionary());
@@ -4149,6 +4149,9 @@ class NameDictionary: public Dictionary<NameDictionary,
// Find entry for key, otherwise return kNotFound. Optimized version of
// HashTable::FindEntry.
+ int FindEntry(Handle<Name> key);
+
+ // TODO(ishell): Remove this when all the callers are handlified.
int FindEntry(Name* key);
// TODO(mstarzinger): Temporary wrapper until handlified.
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698