Ignore:
Timestamp:
Oct 16, 2007, 4:25:33 PM (18 years ago)
Author:
ggaren
Message:

Reviewed by Darin Adler.


Global replace of assert with ASSERT.

File:
1 edited

Legend:

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

    r21018 r26688  
    2727#include "PropertyNameArray.h"
    2828#include <algorithm>
     29#include <wtf/Assertions.h>
    2930#include <wtf/FastMalloc.h>
    3031#include <wtf/Vector.h>
     
    160161JSValue *PropertyMap::get(const Identifier &name, unsigned &attributes) const
    161162{
    162     assert(!name.isNull());
     163    ASSERT(!name.isNull());
    163164   
    164165    UString::Rep *rep = name._ustring.rep();
     
    201202JSValue *PropertyMap::get(const Identifier &name) const
    202203{
    203     assert(!name.isNull());
     204    ASSERT(!name.isNull());
    204205   
    205206    UString::Rep *rep = name._ustring.rep();
     
    238239JSValue **PropertyMap::getLocation(const Identifier &name)
    239240{
    240     assert(!name.isNull());
     241    ASSERT(!name.isNull());
    241242   
    242243    UString::Rep *rep = name._ustring.rep();
     
    295296void PropertyMap::put(const Identifier &name, JSValue *value, int attributes, bool roCheck)
    296297{
    297     assert(!name.isNull());
    298     assert(value != 0);
     298    ASSERT(!name.isNull());
     299    ASSERT(value != 0);
    299300   
    300301    checkConsistency();
     
    382383void PropertyMap::insert(UString::Rep *key, JSValue *value, int attributes, int index)
    383384{
    384     assert(m_u.table);
     385    ASSERT(m_u.table);
    385386
    386387    unsigned h = key->hash();
     
    394395#endif
    395396    while (entries[i].key) {
    396         assert(entries[i].key != deletedSentinel());
     397        ASSERT(entries[i].key != deletedSentinel());
    397398        if (k == 0)
    398399            k = 1 | (h % sizeMask);
     
    418419void PropertyMap::rehash()
    419420{
    420     assert(m_u.table);
    421     assert(m_u.table->size);
     421    ASSERT(m_u.table);
     422    ASSERT(m_u.table->size);
    422423    rehash(m_u.table->size);
    423424}
     
    449450        // the table key count
    450451        ++m_u.table->keyCount;
    451         assert(m_u.table->keyCount == 1);
     452        ASSERT(m_u.table->keyCount == 1);
    452453    }
    453454#endif
     
    472473void PropertyMap::remove(const Identifier &name)
    473474{
    474     assert(!name.isNull());
     475    ASSERT(!name.isNull());
    475476   
    476477    checkConsistency();
     
    523524    entries[i].value = 0;
    524525    entries[i].attributes = DontEnum;
    525     assert(m_u.table->keyCount >= 1);
     526    ASSERT(m_u.table->keyCount >= 1);
    526527    --m_u.table->keyCount;
    527528    ++m_u.table->sentinelCount;
     
    702703                *p++ = e;
    703704        }
    704         assert(p - sortedEntries.data() == count);
     705        ASSERT(p - sortedEntries.data() == count);
    705706
    706707        // Sort the entries by index.
     
    750751            i = (i + k) & m_u.table->sizeMask;
    751752        }
    752         assert(i == j);
     753        ASSERT(i == j);
    753754        ++count;
    754755    }
    755     assert(count == m_u.table->keyCount);
    756     assert(sentinelCount == m_u.table->sentinelCount);
    757     assert(m_u.table->size >= 16);
    758     assert(m_u.table->sizeMask);
    759     assert(m_u.table->size == m_u.table->sizeMask + 1);
     756    ASSERT(count == m_u.table->keyCount);
     757    ASSERT(sentinelCount == m_u.table->sentinelCount);
     758    ASSERT(m_u.table->size >= 16);
     759    ASSERT(m_u.table->sizeMask);
     760    ASSERT(m_u.table->size == m_u.table->sizeMask + 1);
    760761}
    761762
Note: See TracChangeset for help on using the changeset viewer.