Boost logo

Boost :

From: John Maddock (john_maddock_at_[hidden])
Date: 2002-05-18 06:01:33


> Here's a request for a frequently needed type_traits-like feature, as
> well as comments on a generally needed structure.
>
> I often need when manipulating elementary types (char, unsigned char)
> that I want a conversion such as:
>
> boost::add_unsigned<T>::type returns the unsigned integral type,
> for builtin integral types (bool,
> char, short, int, long int, and
> their variants), and T otherwise
>
> boost::add_signed<T>::type returns the signed integral type,
> for builtin integral types (bool,
> char, short, int, long int, and
> their variants), and T otherwise

Yes, I think those would be useful additions, there are a few type_traits
requests building up now, I'm not sure when I'll get around to them all
though....

John Maddock
http://ourworld.compuserve.com/homepages/john_maddock/index.htm


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