|
Boost : |
Subject: Re: [boost] [Boost.Pool] TR1?
From: Dave Abrahams (dave_at_[hidden])
Date: 2011-04-13 18:33:59
At Wed, 13 Apr 2011 21:44:04 +0200,
Anders Dalvander wrote:
>
> On 2011-04-13 20:22, Dave Abrahams wrote:
> > If you test it with std::less you can get false positives.
>
> Please forgive me for continuing further down this road and for being OT.
>
> But I don't understand how the std::less approach would give false
> positives. Care to explain, or direct me to a better location for
> getting the answer?
std::less<T*> could produce a total ordering such that
std::less<T*>()(x,y) && std::less<T*>()(y,z)
when [x,z) denotes an allocated memory block and y denotes an address
outside that block. The ordering produced by comparing addresses with
their bits permuted in a given way is an example.
-- Dave Abrahams BoostPro Computing http://www.boostpro.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk