Skip to content

Commit

Permalink
use auto when initializing header from cast
Browse files Browse the repository at this point in the history
  • Loading branch information
stevenmeker committed Dec 3, 2024
1 parent e27ec1b commit d23fd35
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions runtime/alloc/arena.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ void arena::initialize_semispace() {
// We put a memory_block_header at the beginning so we can identify the semispace a pointer belongs to
// id by masking off the low bits to access this memory_block_header.
//
memory_block_header *header
= reinterpret_cast<memory_block_header *>(current_addr_ptr);
auto *header = reinterpret_cast<memory_block_header *>(current_addr_ptr);
header->semispace = allocation_semispace_id;
allocation_ptr = current_addr_ptr + sizeof(arena::memory_block_header);
//
Expand Down

0 comments on commit d23fd35

Please sign in to comment.