Ignore:
Timestamp:
Oct 7, 2008, 11:17:37 AM (17 years ago)
Author:
[email protected]
Message:

2008-10-07 Cameron Zwarich <[email protected]>

Rubber-stamped by Mark Rowe.

Roll out r37370.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/JSObject.cpp

    r37370 r37381  
    135135   
    136136    unsigned attributes;
    137     if ((m_structureID->propertyMap().get(propertyName, attributes) != WTF::notFound) && attributes & ReadOnly)
     137    if ((m_structureID->propertyMap().getOffset(propertyName, attributes) != WTF::notFound) && attributes & ReadOnly)
    138138        return;
    139139
     
    201201{
    202202    unsigned attributes;
    203     if (m_structureID->propertyMap().get(propertyName, attributes) != WTF::notFound) {
     203    if (m_structureID->propertyMap().getOffset(propertyName, attributes) != WTF::notFound) {
    204204        if ((attributes & DontDelete))
    205205            return false;
     
    413413bool JSObject::getPropertyAttributes(ExecState* exec, const Identifier& propertyName, unsigned& attributes) const
    414414{
    415     if (m_structureID->propertyMap().get(propertyName, attributes) != WTF::notFound)
     415    if (m_structureID->propertyMap().getOffset(propertyName, attributes) != WTF::notFound)
    416416        return true;
    417417   
     
    469469void JSObject::removeDirect(const Identifier& propertyName)
    470470{
    471     size_t offset;
    472471    if (m_structureID->isDictionary()) {
    473         offset = m_structureID->propertyMap().remove(propertyName);
    474         if (offset != WTF::notFound) {
    475             m_propertyStorage[offset] = jsUndefined();
    476             m_structureID->clearEnumerationCache();
    477         }
     472        m_structureID->propertyMap().remove(propertyName, m_propertyStorage);
     473        m_structureID->clearEnumerationCache();
    478474        return;
    479475    }
    480476
    481477    RefPtr<StructureID> structureID = StructureID::toDictionaryTransition(m_structureID);
    482     offset = structureID->propertyMap().remove(propertyName);
    483     if (offset != WTF::notFound)
    484         m_propertyStorage[offset] = jsUndefined();
     478    structureID->propertyMap().remove(propertyName, m_propertyStorage);
    485479    setStructureID(structureID.release());
    486480}
     
    507501void JSObject::allocatePropertyStorage(size_t oldSize, size_t newSize)
    508502{
    509     ASSERT(newSize > oldSize);
    510 
    511503    JSValue** oldPropertStorage = m_propertyStorage;
    512504    m_propertyStorage = new JSValue*[newSize];
Note: See TracChangeset for help on using the changeset viewer.