Ignore:
Timestamp:
May 10, 2009, 10:32:44 AM (16 years ago)
Author:
[email protected]
Message:

Reviewed by Geoff Garen.

"Class const *" is the same as "const Class*", use the latter syntax consistently.

See <http://www.parashift.com/c++-faq-lite/const-correctness.html#faq-18.9>.

  • pcre/pcre_compile.cpp: (calculateCompiledPatternLength):
  • runtime/JSObject.h: (JSC::JSObject::offsetForLocation): (JSC::JSObject::locationForOffset):
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/runtime/JSObject.h

    r43432 r43461  
    5353
    5454    typedef EncodedJSValue* PropertyStorage;
    55     typedef EncodedJSValue const * ConstPropertyStorage;
     55    typedef const EncodedJSValue* ConstPropertyStorage;
    5656
    5757    class JSObject : public JSCell {
     
    150150        size_t offsetForLocation(JSValue* location) const
    151151        {
    152             return location - reinterpret_cast<JSValue const *>(propertyStorage());
    153         }
    154 
    155         JSValue const * locationForOffset(size_t offset) const
    156         {
    157             return reinterpret_cast<JSValue const *>(&propertyStorage()[offset]);
     152            return location - reinterpret_cast<const JSValue*>(propertyStorage());
     153        }
     154
     155        const JSValue* locationForOffset(size_t offset) const
     156        {
     157            return reinterpret_cast<const JSValue*>(&propertyStorage()[offset]);
    158158        }
    159159
Note: See TracChangeset for help on using the changeset viewer.