Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2005-03-13 14:12:41

Thorsten Ottosen wrote:
> "David Abrahams" <dave_at_[hidden]> wrote in message
>> There's no guarantee that the integer type will have sufficient size.
> BOOST_STATIC_ASSERT( sizeof(void*) >= sizeof(std::size_t))
> ?

The reverse, probably. Technically, it's still not enough; sizeof gives you
the size of the object in chars, not the number of value bits. This aside,
the assert doesn't tell you whether reinterpret_cast produces a reasonable
hash value; this is an inherently non-portable characteristic of the
particular platform.

Boost list run by bdawes at, gregod at, cpdaniel at, john at