Boost logo

Boost Users :

Subject: [Boost-users] Bug using mpl with <ciso646> and MSVC?
From: ebryan (bryan.12_at_[hidden])
Date: 2009-12-18 18:30:02


I am using Spirit with some code that uses the keywords 'and', 'or', etc.
MSVC (at least my version, 9.0) does not implement these keywords, but
support can be added by including <ciso646>, which just has a bunch of
macros, ie. "#define and &&".

The problem I am running into is that when I try to compile something that
uses Spirit and ciso646, I get this compiler error:

boost\mpl\aux_\include_preprocessed.hpp(37) : fatal error C1083: Cannot open
include file: 'boost/mpl/aux_/preprocessed/plain/&.hpp': No such file or

The offending line in include_preprocessed.hpp is:

# include

It looks like the macro 'bitand' is being expanded in here, so it tries to
include '&.hpp'.

Now, I think this problem has already been solved (mostly). See this
archived discussion, where this problem was worked around for 'and' and

I have checked the header files in boost/mpl and only see three more
conflicts between header names and ciso646 macros: 'bitand', 'bitor', and
'not'. If someone with more expertise than myself could implement a similar
workaround for these headers, I would be very grateful.


View this message in context:
Sent from the Boost - Users mailing list archive at

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at