Use placement new to avoid memory allocations.