Changeset 280687 in webkit
- Timestamp:
- Aug 5, 2021, 8:14:42 AM (5 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 3 edited
-
ChangeLog (modified) (1 diff)
-
KeywordLookupGenerator.py (modified) (2 diffs)
-
runtime/PropertyMapHashTable.h (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r280659 r280687 1 2021-08-05 Zan Dobersek <zdobersek@igalia.com> 2 3 Use reinterpret_cast_ptr in KeywordLookupGenerator, PropertyMapHashTable 4 https://bugs.webkit.org/show_bug.cgi?id=228819 5 6 Reviewed by Adrian Perez de Castro. 7 8 Switch to using reinterpret_cast_ptr in KeywordLookupGenerator (which 9 generates the KeywordLookup.h header) and PropertyMapHashTable, reducing 10 a bit the GCC warning spewage when compiling for targets benefitting 11 from the reinterpret_cast_ptr workaround. 12 13 * KeywordLookupGenerator.py: 14 * runtime/PropertyMapHashTable.h: 15 (JSC::PropertyTable::table): 16 (JSC::PropertyTable::table const): 17 1 18 2021-08-04 Yijia Huang <yijia_huang@apple.com> 2 19 -
trunk/Source/JavaScriptCore/KeywordLookupGenerator.py
r258531 r280687 220 220 print("// This file was generated by KeywordLookupGenerator.py. Do not edit.") 221 221 print(""" 222 #include <wtf/StdLibExtras.h> 223 222 224 #if CPU(NEEDS_ALIGNED_ACCESS) 223 225 … … 259 261 260 262 #define COMPARE_2CHARS(address, char1, char2) \\ 261 ((reinterpret_cast <const uint16_t*>(address))[0] == CHARPAIR_TOUINT16(char1, char2))263 ((reinterpret_cast_ptr<const uint16_t*>(address))[0] == CHARPAIR_TOUINT16(char1, char2)) 262 264 #define COMPARE_2UCHARS(address, char1, char2) \\ 263 ((reinterpret_cast <const uint32_t*>(address))[0] == UCHARPAIR_TOUINT32(char1, char2))265 ((reinterpret_cast_ptr<const uint32_t*>(address))[0] == UCHARPAIR_TOUINT32(char1, char2)) 264 266 265 267 #if CPU(X86_64) 266 268 267 269 #define COMPARE_4CHARS(address, char1, char2, char3, char4) \\ 268 ((reinterpret_cast <const uint32_t*>(address))[0] == CHARQUAD_TOUINT32(char1, char2, char3, char4))270 ((reinterpret_cast_ptr<const uint32_t*>(address))[0] == CHARQUAD_TOUINT32(char1, char2, char3, char4)) 269 271 #define COMPARE_4UCHARS(address, char1, char2, char3, char4) \\ 270 ((reinterpret_cast <const uint64_t*>(address))[0] == UCHARQUAD_TOUINT64(char1, char2, char3, char4))272 ((reinterpret_cast_ptr<const uint64_t*>(address))[0] == UCHARQUAD_TOUINT64(char1, char2, char3, char4)) 271 273 272 274 #else // CPU(X86_64) -
trunk/Source/JavaScriptCore/runtime/PropertyMapHashTable.h
r273138 r280687 27 27 #include <wtf/HashTable.h> 28 28 #include <wtf/MathExtras.h> 29 #include <wtf/StdLibExtras.h> 29 30 #include <wtf/Vector.h> 30 31 #include <wtf/text/AtomStringImpl.h> … … 549 550 { 550 551 // The table of values lies after the hash index. 551 return reinterpret_cast <ValueType*>(m_index + m_indexSize);552 return reinterpret_cast_ptr<ValueType*>(m_index + m_indexSize); 552 553 } 553 554 … … 555 556 { 556 557 // The table of values lies after the hash index. 557 return reinterpret_cast <const ValueType*>(m_index + m_indexSize);558 return reinterpret_cast_ptr<const ValueType*>(m_index + m_indexSize); 558 559 } 559 560
Note:
See TracChangeset
for help on using the changeset viewer.