
28 Nov
2007
28 Nov
'07
10:38 p.m.
Hi, Are there lexical specializations such as (approximately): template<long, std::string> long lexical_cast( const std::string & refStr ) { return atoi( refStr.c_str() ); } This is of course less strict and clean as the general templates, but may be faster, with smaller code, given there are very fast implementations of atoi. This can be easily generalized to strtod() etc... Thanks.