Index: src/objects.h |
diff --git a/src/objects.h b/src/objects.h |
index a190f8dfe21bfba620ba73614d68a993f3b05a67..c5bd55a2fc80d1d5dac62fc17b0e389ba6b23334 100644 |
--- a/src/objects.h |
+++ b/src/objects.h |
@@ -3893,6 +3893,8 @@ class HashTableKey { |
// Returns the key object for storing into the hash table. |
// If allocations fails a failure object is returned. |
MUST_USE_RESULT virtual MaybeObject* AsObject(Heap* heap) = 0; |
+ // TODO(ishell): This should eventually replace AsObject(). |
+ inline Handle<Object> AsHandle(Isolate* isolate); |
// Required. |
virtual ~HashTableKey() {} |
}; |
@@ -3930,12 +3932,10 @@ class StringTable: public HashTable<StringTable, |
StringTableShape, |
HashTableKey*> { |
public: |
- // Find string in the string table. If it is not there yet, it is |
- // added. The return value is the string table which might have |
- // been enlarged. If the return value is not a failure, the string |
- // pointer *s is set to the string found. |
- MUST_USE_RESULT MaybeObject* LookupString(String* key, Object** s); |
- MUST_USE_RESULT MaybeObject* LookupKey(HashTableKey* key, Object** s); |
+ // Find string in the string table. If it is not there yet, it is |
+ // added. The return value is the string found. |
+ static Handle<String> LookupString(Isolate* isolate, Handle<String> key); |
+ static Handle<String> LookupKey(Isolate* isolate, HashTableKey* key); |
// Looks up a string that is equal to the given string and returns |
// true if it is found, assigning the string to the given output |
@@ -9225,6 +9225,7 @@ class String: public Name { |
static const int32_t kMaxOneByteCharCode = unibrow::Latin1::kMaxChar; |
static const uint32_t kMaxOneByteCharCodeU = unibrow::Latin1::kMaxChar; |
static const int kMaxUtf16CodeUnit = 0xffff; |
+ static const uint32_t kMaxUtf16CodeUnitU = kMaxUtf16CodeUnit; |
// Value of hash field containing computed hash equal to zero. |
static const int kEmptyStringHash = kIsNotArrayIndexMask; |