pool: avoid unsigned/signed type conversion warnings
This commit is contained in:
parent
c718c9bff4
commit
6fba251a38
@ -51,13 +51,13 @@ void
|
||||
check_keep_value (cruft::TAP::logger &tap)
|
||||
{
|
||||
// Ensure that items keep their values.
|
||||
cruft::pool<uint64_t> uintpool(256);
|
||||
std::vector<uint64_t*> uintvector;
|
||||
cruft::pool<std::size_t> uintpool(256);
|
||||
std::vector<std::size_t*> uintvector;
|
||||
uintvector.reserve(uintpool.capacity ());
|
||||
|
||||
// Give every item a unique value
|
||||
for (unsigned int i = 0; i < uintpool.capacity (); ++i) {
|
||||
uint64_t *item = uintpool.allocate ();
|
||||
for (std::size_t i = 0; i < uintpool.capacity (); ++i) {
|
||||
std::size_t *item = uintpool.allocate ();
|
||||
*item = i;
|
||||
|
||||
uintvector.push_back(item);
|
||||
|
Loading…
Reference in New Issue
Block a user