Bug using mpl with <ciso646> and MSVC?

Hello, 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 directory The offending line in include_preprocessed.hpp is: # include BOOST_PP_STRINGIZE(boost/mpl/aux_/preprocessed/AUX778076_PREPROCESSED_HEADER) 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 'or': http://lists.boost.org/Archives/boost/2004/05/65563.php 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. Thanks, Erik -- View this message in context: http://old.nabble.com/Bug-using-mpl-with-%3Cciso646%3E-and-MSVC--tp26851153p... Sent from the Boost - Users mailing list archive at Nabble.com.

I got this working with a pretty direct copy/paste/find/replace using the current and.hpp as a template. See these links for the contents of my bitand.hpp and bitor.hpp: http://pastebin.com/f1afd8b3e http://pastebin.com/f47c85a29 It turns out that even though there is a not.hpp file, and ciso646 defines the macro 'not', it doesn't cause problems, at least for me. This might still cause issues down the road, maybe not. I'm not really sure what's going on in not.hpp. I don't know how this kind of thing works, but this seems like a legitimate (if obscure) problem in need of an official workaround. How do I go about getting this little fix uploaded to the boost repositories? Should I email the mpl maintainers directly, or do they read this list fairly often? Thanks, Erik Bryan -- View this message in context: http://old.nabble.com/Bug-using-mpl-with-%3Cciso646%3E-and-MSVC--tp26851153p... Sent from the Boost - Users mailing list archive at Nabble.com.
participants (1)
-
ebryan