Changeset 36032 in webkit for trunk/JavaScriptCore/kjs/JSObject.h
- Timestamp:
- Sep 2, 2008, 7:31:45 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/kjs/JSObject.h
r36016 r36032 31 31 #include "PropertyMap.h" 32 32 #include "PropertySlot.h" 33 #include "PutPropertySlot.h" 33 34 #include "ScopeChain.h" 34 35 #include "StructureID.h" … … 53 54 54 55 class JSObject : public JSCell { 56 friend class BatchedTransitionOptimizer; 57 55 58 public: 56 59 JSObject(PassRefPtr<StructureID>); … … 65 68 void setPrototype(JSValue* prototype); 66 69 67 PassRefPtr<StructureID>inheritorID();70 StructureID* inheritorID(); 68 71 69 72 virtual UString className() const; … … 153 156 const HashEntry* findPropertyHashEntry(ExecState*, const Identifier& propertyName) const; 154 157 void setStructureID(PassRefPtr<StructureID>); 155 PassRefPtr<StructureID>createInheritorID();158 StructureID* createInheritorID(); 156 159 157 160 PropertyMap m_propertyMap; … … 162 165 163 166 inline JSObject::JSObject(JSObject* prototype) 164 : JSCell(prototype->inheritorID() .releaseRef()) // ~JSObject balances this ref()167 : JSCell(prototype->inheritorID()) 165 168 { 166 169 ASSERT(m_structureID); 167 170 ASSERT(this->prototype()); 168 ASSERT(this->prototype() == jsNull() || Heap::heap(this) == Heap::heap(this->prototype())); 171 ASSERT(this->prototype()->isNull() || Heap::heap(this) == Heap::heap(this->prototype())); 172 m_structureID->ref(); // ~JSObject balances this ref() 169 173 } 170 174 … … 199 203 } 200 204 201 inline PassRefPtr<StructureID>JSObject::inheritorID()205 inline StructureID* JSObject::inheritorID() 202 206 { 203 207 if (m_inheritorID)
Note:
See TracChangeset
for help on using the changeset viewer.