Boost logo

Boost :

From: Thomas Witt (witt_at_[hidden])
Date: 2002-10-02 07:02:14


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wednesday 02 October 2002 13:09, David Abrahams wrote:
>
> Why is everyone barking up this tree instead of using shared_ptr<T const>
> "as god intended"?

Maybe because we're missing a type trait

template <class T>
class add_const_to_value;

that can be used like this

template <class Pointer>
void foo(typename add_const_to_value<Pointer>::type pointer_to_const_object);

Maybe because constness of pointers/objects is not a generally well understood
topic.

- ---Thomas

- --
Dipl.-Ing. Thomas Witt
Institut fuer Verkehrswesen, Eisenbahnbau und -betrieb, Universitaet Hannover
voice: +49(0) 511 762 - 4273, fax: +49(0) 511 762-3001
http://www.ive.uni-hannover.de
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9muBJ0ds/gS3XsBoRAmqwAKCOptKR6YN65T3V7Dk/IxNH9yXQBgCbBB8G
ZAeVsnC0B6jPdn8zpUiHJHg=
=xSWN
-----END PGP SIGNATURE-----


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