diff options
author | 2016-10-22 11:31:49 +0200 | |
---|---|---|
committer | 2016-10-22 11:31:49 +0200 | |
commit | 23ad94073f4c2f7131fa0c95b6202f2f9027db41 (patch) | |
tree | 4f4e1e27a22ace8fea49b63030d4462db7cb68a1 /src/emu/emualloc.cpp | |
parent | 255bf78b316a9dc9e4c53a65143000471a6927d3 (diff) |
use standard types uintptr_t, char16_t and char32_t instead of FPTR, utf16_char, unicode_char (nw)
Diffstat (limited to 'src/emu/emualloc.cpp')
-rw-r--r-- | src/emu/emualloc.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/emu/emualloc.cpp b/src/emu/emualloc.cpp index f424bca39cb..39f42378499 100644 --- a/src/emu/emualloc.cpp +++ b/src/emu/emualloc.cpp @@ -67,7 +67,7 @@ void resource_pool::add(resource_pool_item &item, size_t size, const char *type) std::lock_guard<std::mutex> lock(m_listlock); // insert into hash table - int hashval = reinterpret_cast<FPTR>(item.m_ptr) % m_hash_size; + int hashval = reinterpret_cast<uintptr_t>(item.m_ptr) % m_hash_size; item.m_next = m_hash[hashval]; m_hash[hashval] = &item; @@ -121,7 +121,7 @@ void resource_pool::remove(void *ptr) // search for the item std::lock_guard<std::mutex> lock(m_listlock); - int hashval = reinterpret_cast<FPTR>(ptr) % m_hash_size; + int hashval = reinterpret_cast<uintptr_t>(ptr) % m_hash_size; for (resource_pool_item **scanptr = &m_hash[hashval]; *scanptr != nullptr; scanptr = &(*scanptr)->m_next) // must match the pointer @@ -160,7 +160,7 @@ resource_pool_item *resource_pool::find(void *ptr) // search for the item std::lock_guard<std::mutex> lock(m_listlock); - int hashval = reinterpret_cast<FPTR>(ptr) % m_hash_size; + int hashval = reinterpret_cast<uintptr_t>(ptr) % m_hash_size; resource_pool_item *item; for (item = m_hash[hashval]; item != nullptr; item = item->m_next) if (item->m_ptr == ptr) |