Boost logo

Boost :

Subject: Re: [boost] [Boost.Pool] TR1?
From: Dave Abrahams (dave_at_[hidden])
Date: 2011-04-11 21:02:04


At Mon, 11 Apr 2011 12:47:07 -0700,
Phil Bouchard wrote:
>
> Greetings,
>
> I see the Boost.Pool is not making its way up to the C++ standards yet
> an it is very unfortunate given its great use. Boost.Pool provides an
> is_from() member function that does a simple range check and returns
> whether a pointer is part of the pool or not. This is a very useful
> function which I think should be part of the standards because it
> could be used for the global pool as well; i.e. the one used by
> operator ::new and ::delete. The benefits outweigh the costs.

Whatever the costs, you have a point because this is something that
can only be implemented portably by the standard. I'm certain that
Boost.Pool invokes undefined behavior whenever it returns false from
is_from().

-- 
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