Boost logo

Boost :

From: Aleksey Gurtovoy (agurtovoy_at_[hidden])
Date: 2002-06-20 14:55:08


David Abrahams wrote:
> Actually, identity<> is also a fine name for a type envelope: it's used to
> transmit the identity of a type, its parameter... and I'd rather have just
> one template than two.

I agree with the name sentiment, but IMO merging the true metafunction
template with a type-envelope template mostly used to drive function
template overloading would be exactly that kind of reuse that is more harm
than good. For one thing, 'indentity' template belongs to the 'boost::mpl'
namespace :). Another thing is unwanted dependences - the type-envelope
shouldn't depend of anything else, while it's acceptable for
'mpl::indentity' to depend on something (light-weight) related to
meta-function concept - etc.

> However, I know there was what seemed like rancorous objection when I
> suggested identity<> before; nobody seemed to get the whole metafunction
> idea, so for the record, I don't care all that much what we call it.

Me too, although 'type_wrapper' seems to be slightly less cryptic.

Aleksey


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