Boost logo

Boost :

Subject: Re: [boost] Spirit V1.8 to V2.1 Porting Errors
From: Hartmut Kaiser (hartmut.kaiser_at_[hidden])
Date: 2010-02-25 11:18:39

> Trying to port the code to V2.1, a number of redefinition errors get
> generated by the compiler. The first instance is the extern
> InterLockedIncrement variable at line 73 of the interlocked.hpp file.
> The
> code is segmented for different platforms using #if #elif and so on
> directives. The project is at the same time ported from Visual Studio
> 2008
> to 2010 RC1, and the redefinition error is caused by compiler not
> excluding
> parts of that file. The define by the Visual Studio is the _WIN32_WINNT
> base
> on the use of the 32 bit development PC. This definition is not listed
> by
> the #elif chain within the interlocked.hpp code and it seems that
> BOOST_USE_WINDOWS_H is used instead. Knowing the segments are coded to
> be
> mutually exclusive, still the code generates errors?

I doubt this has anything to do with Spirit as it doesn't make any use of
InterLockedIncrement. AFAIR it doesn't even (directly) include windows.h.

Please provide a minimal example exposing your problem, otherwise it's
almost impossible to help.

Regards Hartmut

Meet me at BoostCon

Boost list run by bdawes at, gregod at, cpdaniel at, john at