Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2002-09-23 09:07:43


From: "Peter Dimov" <pdimov_at_[hidden]>

> From: "Douglas Gregor" <gregod_at_[hidden]>
> >
> > Well, if the type were actually stateless, it wouldn't matter if we
stored
> a
> > copy or not. But the definition of stateless doesn't account for this
type
> of
> > location-dependence, so Function is wrong here.
>
> is_stateless (def): all instances of the type are equivalent.

Much better, and it doesn't require zero size!

Might be harder for the compiler to detect, though.

The conditions I suggested earlier could still be used as an additional
optimization in the case where stateless<T>::value == false... someday.

-----------------------------------------------------------
           David Abrahams * Boost Consulting
dave_at_[hidden] * http://www.boost-consulting.com


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk