Boost logo

Boost Users :

From: Holger Grund (yahoo_at_[hidden])
Date: 2004-02-25 17:39:09


"Robert McKinnon" <rmckinnon_at_[hidden]> wrote

>
> I am trying to incorporate the boost::regex into an ATL project that I
> am working on. Everything seems to work well until I try to use the
> regex_replace function. When I compile I get the following error:
>
> =====
> Creating library Debug/yetan.lib and object Debug/yetan.exp
> test.obj : error LNK2001: unresolved external symbol "void __cdecl
> boost::throw_exception(class exception const &)"
> (?throw_exception_at_boost@@YAXABVexception@@@Z)

I think it's related to the /GX or /EHsc compiler options.
IIRC ATL 3 project wizards turn this options off by default (at
the very least in the Min Dependency config)

The easiest thing would be to compile with C++ exceptions
support turned on. Please note, though, that this requires the
CRT.

Otherwise you're supposed to provide an implementation of
boost::throw_exception.

You could just terminate or raise a structured exception with
Windows' RaiseException API. No unwinding happens in the
latter case (that is object with automatic storage duration won't
have their dtors called).

-hg


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net