Changeset 52500 in webkit for trunk/JavaScriptCore/runtime/UStringImpl.h
- Timestamp:
- Dec 22, 2009, 2:05:17 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/runtime/UStringImpl.h
r52470 r52500 45 45 UntypedPtrAndBitfield(void* ptrValue, uintptr_t bitValue) 46 46 : m_value(reinterpret_cast<uintptr_t>(ptrValue) | bitValue) 47 #ifndef NDEBUG 48 , m_leaksPtr(ptrValue) 49 #endif 47 50 { 48 51 ASSERT(ptrValue == asPtr<void*>()); … … 73 76 static const uintptr_t s_alignmentMask = ~static_cast<uintptr_t>(0x7); 74 77 uintptr_t m_value; 78 #ifndef NDEBUG 79 void* m_leaksPtr; // Only used to allow tools like leaks on OSX to detect that the memory is referenced. 80 #endif 75 81 }; 76 82 … … 217 223 , m_dataBuffer(base.releaseRef(), BufferSubstring) 218 224 { 225 // Do use static strings as a base for substrings; UntypedPtrAndBitfield assumes 226 // that all pointers will be at least 8-byte aligned, we cannot guarantee that of 227 // UStringImpls that are not heap allocated. 228 ASSERT(m_dataBuffer.asPtr<UStringImpl*>()->size()); 229 ASSERT(!m_dataBuffer.asPtr<UStringImpl*>()->isStatic()); 219 230 checkConsistency(); 220 231 }
Note:
See TracChangeset
for help on using the changeset viewer.