$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Felipe Magno de Almeida (felipe.m.almeida_at_[hidden])
Date: 2006-04-04 02:09:56
Hi,
the file hash_map.hpp has a bug, caught by STLPort checked-STL.
The clear member-function is:
// Remove all entries from the map.
void clear()
{
// Initialise all buckets to empty.
for (size_t i = 0; i < num_buckets; ++i)
buckets_[i].first = buckets_[i].last = values_.end();
// Clear the values.
values_.clear();
}
But the clear member function of values_invalidates all iterators. So,
the values recorded in the buckets are all invalidated. Which is
caught in a later call to insert.
I've swapped the clear call above the for and everything is fine here.
best regards,
-- Felipe Magno de Almeida