Boost C++ Libraries: Ticket #2458: 1.36.0 Regex will not compile under MSVC 8.0 https://svn.boost.org/trac10/ticket/2458 <p> I get the following error (repeated several times) when I build the boost libraries using MSVC 8.0 (8.0.50727.42): </p> <p> ...failed compile-c-c++ bin.v2\libs\regex\build\msvc-8.0\debug\link-static\threading-multi\wc_regex_traits.obj... compile-c-c++ bin.v2\libs\regex\build\msvc-8.0\debug\link-static\threading-multi\usinstances.obj usinstances.cpp libs\regex\src\..\src\usinstances.cpp(55) : error C2375: 'std::allocator&lt;_Ty&gt;::allocator' : redefinition; different link age </p> <blockquote> <p> with [ </p> <blockquote> <p> _Ty=unsigned short </p> </blockquote> <p> ] C:\Program Files\Microsoft Visual Studio 8\VC\INCLUDE\xmemory(120) : see declaration of 'std::allocator&lt;_Ty&gt;::al </p> </blockquote> <p> locator' </p> <blockquote> <p> with [ </p> <blockquote> <p> _Ty=unsigned short </p> </blockquote> <p> ] </p> </blockquote> <p> libs\regex\src\..\src\usinstances.cpp(55) : error C3190: 'std::allocator&lt;_Ty&gt;::allocator(void) throw()' with the provide d template arguments is not the explicit instantiation of any member function of 'std::allocator&lt;_Ty&gt;' </p> <blockquote> <p> with [ </p> <blockquote> <p> _Ty=unsigned short </p> </blockquote> <p> ] </p> </blockquote> <p> Commenting out the line: </p> <p> template _CRTIMP2 allocator&lt;unsigned short&gt;::allocator(); </p> <p> where it appears in usinstances.cpp and workaround.hpp seems to solve the problem. In the MSVC definition of this function, it includes "throw()", which causes the conflict. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/2458 Trac 1.4.3 john@… Fri, 31 Oct 2008 23:55:03 GMT <link>https://svn.boost.org/trac10/ticket/2458#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2458#comment:1</guid> <description> <p> Should be wc_regex_changes.cpp, not workaround.hpp. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>John Maddock</dc:creator> <pubDate>Mon, 22 Dec 2008 12:19:58 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/2458#comment:2 https://svn.boost.org/trac10/ticket/2458#comment:2 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> I believe this is fixed in Trunk. </p> <p> Alternatively installing VC8 service pack 1 will fix the issue. </p> Ticket