Boost logo

Boost :

From: Douglas Gregor (gregod_at_[hidden])
Date: 2002-01-24 10:17:11


On Thursday 24 January 2002 10:10 am, you wrote:
> I just wrote this:
>
> template<class V> std::string to_string(V const & v)
> {
> std::ostringstream os;
> os << v;
> return os.str();
> }
>
> template<> std::string to_string(std::string const & v)
> {
> return v;
> }
>
> for Nth time. Why don't we have this in Boost? And where should it go?

Why not use boost::lexical_cast<std::string>(something_to_convert)?

        Doug


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