Subject: [Boost-bugs] [Boost C++ Libraries] #12233: boost::regex doesn't compile with clang on windows
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2016-05-28 18:12:48
#12233: boost::regex doesn't compile with clang on windows
--------------------------------------+-------------------------
Reporter: Ä°smail Dönmez <ismail@â¦> | Owner: johnmaddock
Type: Bugs | Status: new
Milestone: To Be Determined | Component: regex
Version: Boost 1.61.0 | Severity: Problem
Keywords: |
--------------------------------------+-------------------------
Trying to compile a simple example:
{{{
#include <boost/regex.hpp>
#include <string>
#include <iostream>
int main()
{
std::string s = "Boost Libraries";
boost::regex expr{"\\w+\\s\\w+"};
std::cout << std::boolalpha << boost::regex_match(s, expr) << '\n';
}
}}}
with
{{{
latte ~\Desktop > clang-cl /D_CRT_SECURE_NO_WARNINGS /MT -I
C:\boost-1.61.0 .\b2.cpp C:\boost-1.61.0\lib64-msvc-14.0\lib
boost_regex-vc140-mt-s-1_61.lib
b2-807015.obj : error LNK2019: unresolved external symbol "public: bool
__cdecl
boost::re_detail_106100::abstract_protected_call::execute(void)const "
(?execute_at_abstract_protected_call_at_re_detail_106100_at_boost@@QEBA_NXZ)
referenced in function "private: bool __cdecl
boost::re_detail_106100::perl_matcher<class
std::_String_const_iterator<class std::_String_val<struct
std::_Simple_types<char> > >,class std::allocator<struct
boost::sub_match<class std::_String_const_iterator<class
std::_String_val<struct std::_Simple_types<char> > > > >,struct
boost::regex_traits<char,class boost::w32_regex_traits<char> >
>::protected_call(bool (__cdecl
boost::re_detail_106100::perl_matcher<class
std::_String_const_iterator<class std::_String_val<struct
std::_Simple_types<char> > >,class std::allocator<struct
boost::sub_match<class std::_String_const_iterator<class
std::_String_val<struct std::_Simple_types<char> > > > >,struct
boost::regex_traits<char,class boost::w32_regex_traits<char> >
>::*)(void))"
(?protected_call@?$perl_matcher_at_V?$_String_const_iterator_at_V?$_String_val_at_U?$_Simple_types_at_D@std@@@std@@@std@@V?$allocator_at_U?$sub_match_at_V?$_String_const_iterator_at_V?$_String_val_at_U?$_Simple_types_at_D@std@@@std@@@std@@@boost@@@2_at_U?$regex_traits_at_DV?$w32_regex_traits_at_D@boost@@@boost@@@re_detail_106100_at_boost@@AEAA_NP8123_at_EAA_NXZ_at_Z)
b2.exe : fatal error LNK1120: 1 unresolved externals
clang-cl.exe: error: linker command failed with exit code 1120 (use -v to
see invocation)
}}}
This is also reproducible with clang.exe. Test system is Windows 10 x64.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/12233> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:20 UTC