Casting (converting) number in a format with multiple dots (a version number) to string <pre><code>#define EXTERNAL_API_VERSION 1.12.1 std::string version = boost::lexical_cast&lt;std::string&gt;(EXTERNAL_API_VERSION); </code></pre> <p>This code generates a compilation error:</p> <pre><code>error C2143: syntax error : missing ')' before 'constant' error C2059: syntax error : ')' </code></pre> <p>Are there any simple alternatives for casting number in such format (more then one dot) to string?</p>