Boost logo

Boost :

From: Pavel Vozenilek (pavel_vozenilek_at_[hidden])
Date: 2003-08-25 06:39:03


In many cases using memcpy() is faster than copying array of objects one by
one. NTL (http://www.ntllib.org/) claims huge performance gains over STL
using it.

Type traits library may be extended with:
 - memcpy_copyable<> and
 - memcpy_moveable<>

These traits will be specialised for primitive types, pointers,
std::complex, etc. and users will be able to define then for their own
types. Some types may be moveable but not copyable (e.g. typical
std::string).

Containers and algorithms then can take advantage of memcpy() where
possible.

While it is possible for each individual library define such a traits,
having them in Boost.TypeTraits would make them (pseudo)standard.

/Pavel


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