Changeset 37989 in webkit for trunk/JavaScriptCore/runtime/JSObject.h
- Timestamp:
- Oct 29, 2008, 7:44:46 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/runtime/JSObject.h
r37938 r37989 29 29 #include "ExecState.h" 30 30 #include "JSNumberCell.h" 31 #include "PropertyMap.h"32 31 #include "PropertySlot.h" 33 32 #include "PutPropertySlot.h" … … 53 52 }; 54 53 54 typedef JSValue** PropertyStorage; 55 55 56 class JSObject : public JSCell { 56 57 friend class BatchedTransitionOptimizer; … … 124 125 JSValue* getDirect(const Identifier& propertyName) const 125 126 { 126 size_t offset = m_structureID-> propertyMap().get(propertyName);127 size_t offset = m_structureID->get(propertyName); 127 128 return offset != WTF::notFound ? m_propertyStorage[offset] : noValue(); 128 129 } … … 130 131 JSValue** getDirectLocation(const Identifier& propertyName) 131 132 { 132 size_t offset = m_structureID-> propertyMap().get(propertyName);133 size_t offset = m_structureID->get(propertyName); 133 134 return offset != WTF::notFound ? locationForOffset(offset) : 0; 134 135 } … … 136 137 JSValue** getDirectLocation(const Identifier& propertyName, unsigned& attributes) 137 138 { 138 size_t offset = m_structureID-> propertyMap().get(propertyName, attributes);139 size_t offset = m_structureID->get(propertyName, attributes); 139 140 return offset != WTF::notFound ? locationForOffset(offset) : 0; 140 141 } … … 153 154 154 155 void removeDirect(const Identifier& propertyName); 155 bool hasCustomProperties() { return !m_structureID-> propertyMap().isEmpty(); }156 bool hasCustomProperties() { return !m_structureID->isEmpty(); } 156 157 bool hasGetterSetterProperties() { return m_structureID->hasGetterSetterProperties(); } 157 158 … … 221 222 ASSERT(m_structureID); 222 223 ASSERT(m_structureID->propertyStorageCapacity() == inlineStorageCapacity); 223 ASSERT(m_structureID-> propertyMap().isEmpty());224 ASSERT(m_structureID->isEmpty()); 224 225 ASSERT(prototype()->isNull() || Heap::heap(this) == Heap::heap(prototype())); 225 226 } … … 389 390 if (m_structureID->isDictionary()) { 390 391 unsigned currentAttributes; 391 size_t offset = m_structureID-> propertyMap().get(propertyName, currentAttributes);392 size_t offset = m_structureID->get(propertyName, currentAttributes); 392 393 if (offset != WTF::notFound) { 393 394 if (checkReadOnly && currentAttributes & ReadOnly) … … 399 400 400 401 size_t currentCapacity = m_structureID->propertyStorageCapacity(); 401 offset = m_structureID->p ropertyMap().put(propertyName, attributes);402 if (m_structureID->property Map().storageSize() > m_structureID->propertyStorageCapacity()) {402 offset = m_structureID->put(propertyName, attributes); 403 if (m_structureID->propertyStorageSize() > m_structureID->propertyStorageCapacity()) { 403 404 m_structureID->growPropertyStorageCapacity(); 404 405 allocatePropertyStorage(currentCapacity, m_structureID->propertyStorageCapacity()); … … 412 413 413 414 unsigned currentAttributes; 414 size_t offset = m_structureID-> propertyMap().get(propertyName, currentAttributes);415 size_t offset = m_structureID->get(propertyName, currentAttributes); 415 416 if (offset != WTF::notFound) { 416 417 if (checkReadOnly && currentAttributes & ReadOnly)
Note:
See TracChangeset
for help on using the changeset viewer.