diff options
author | Tor Lillqvist <tml@iki.fi> | 2013-08-30 12:04:15 +0300 |
---|---|---|
committer | Tor Lillqvist <tml@iki.fi> | 2013-08-30 12:13:46 +0300 |
commit | 16a4b7ad733f179498e39eac3d4092c55e6c0a07 (patch) | |
tree | df05be0a60bef5b71f022971d4727afd049203e8 /sal/rtl/alloc_arena.cxx | |
parent | fb30ed471eb88870c53c882d623c4f9a7cb0a938 (diff) |
WaE: C4334: '<<' : result of 32-bit shift implicitly converted to 64 bits
1UL is not a portable way to get a size_t -sized one.
Change-Id: I8fac16b7e1f1b8bbccb4bd11eacc9449fc3f8c33
Diffstat (limited to 'sal/rtl/alloc_arena.cxx')
-rw-r--r-- | sal/rtl/alloc_arena.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sal/rtl/alloc_arena.cxx b/sal/rtl/alloc_arena.cxx index 9017a5ac2305..f37d512dffff 100644 --- a/sal/rtl/alloc_arena.cxx +++ b/sal/rtl/alloc_arena.cxx @@ -452,7 +452,7 @@ rtl_arena_segment_alloc ( } /* roundup to next power of 2 */ - size = (1UL << msb); + size = (((sal_Size)1) << msb); } index = lowbit(RTL_MEMORY_P2ALIGN(arena->m_freelist_bitmap, size)); @@ -619,7 +619,7 @@ rtl_arena_constructor (void * obj) head = &(arena->m_freelist_head[i]); rtl_arena_segment_constructor (head); - head->m_size = (1UL << i); + head->m_size = (((sal_Size)1) << i); head->m_type = RTL_ARENA_SEGMENT_TYPE_HEAD; } @@ -658,7 +658,7 @@ rtl_arena_destructor (void * obj) { head = &(arena->m_freelist_head[i]); - assert(head->m_size == (1UL << i)); + assert(head->m_size == (((sal_Size)1) << i)); assert(head->m_type == RTL_ARENA_SEGMENT_TYPE_HEAD); rtl_arena_segment_destructor (head); @@ -694,7 +694,7 @@ rtl_arena_activate ( if (!RTL_MEMORY_ISP2(quantum)) { /* roundup to next power of 2 */ - quantum = (1UL << highbit(quantum)); + quantum = (((sal_Size)1) << highbit(quantum)); } quantum_cache_max = RTL_MEMORY_P2ROUNDUP(quantum_cache_max, quantum); |