Boost logo

Boost-Build :

From: twyonkman (tom.yonkman_at_[hidden])
Date: 2004-03-16 11:44:58


I am trying to link my first test program using regexpp.

Here is the program:

// regexPOSTest.cpp : Defines the entry point for the console
application.
//

#include "stdafx.h"
#include <boost/regex.hpp>
#include <iostream>

int _tmain(int argc, _TCHAR* argv[])
{
boost::regex expression("([0-9]+)(\\-| |$)(.*)",
boost::regbase::normal | boost::regbase::
icase);

char foo[] = "123-abc";

boost::cmatch what;
if(boost::regex_match(foo, what, expression))
{
cout << "Whole match = " << *(what[0].first);
cout << "Response code = " << *(what[1].first);
}

return 0;
}
------------------------

The link error I am getting is:
regexPOSTest.obj : error LNK2019: unresolved external symbol "public:
static void __cdecl boost::w32_regex_traits<char>::
transform_primary(class _STL::basic_string<char,class _STL::
char_traits<char>,class _STL::allocator<char> > &,class _STL::
basic_string<char,class _STL::char_traits<char>,class _STL::
allocator<char> > const &)" (?transform_primary@?
$w32_regex_traits_at_D@boost@@SAXAAV?$basic_string_at_DV?
$char_traits_at_D@_STL@@V?$allocator_at_D@2@@_STL@@ABV34@@Z) referenced in
function "char const * __cdecl boost::re_detail::re_is_set_member(char
const *,char const *,struct boost::re_detail::re_set_long const *,
class boost::reg_expression<char,class boost::regex_traits<char>,class
boost::detail::allocator_adapter<char,class boost::detail::
simple_alloc> > const &)" (?
re_is_set_member_at_re_detail_at_boost@@YAPBDPBD0PBUre_set_long_at_12@ABV?
$reg_expression_at_DV?$regex_traits_at_D@boost@@V?
$allocator_adapter_at_DVsimple_alloc_at_detail@boost@@@detail_at_2@@2@@Z)

The boost_regex_vc7_sssd.lib library is being linked.

Any ideas why the linker can't find the transform_primary (also
transform, I didn't show that link error line) function?

TIA!

Tom Yonkman
tom.yonkman_at_[hidden]

 


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk