Eric,
I changed the files. Should I zip them and post via mailinglist? Or should I submit them somewhere else?

List of files which were changed:

detail/core/linker.hpp
detail/core/matcher/alternate_matcher.hpp
detail/static/productions/alt_compilers.hpp
detail/utility/any.hpp
detail/utility/cons.hpp
proto/op_base.hpp
proto/proto_fwd.hpp
xpressive.hpp

One problem is that xpressive.hpp has info about boost version, but this is the mostly used file for inclusion. Therefore I believe this check fill fail even in boost 1.35:

#if BOOST_VERSION >= 103500
#    ifndef BOOST_XPRESSIVE_FUSION_V2
#        define BOOST_XPRESSIVE_FUSION_V2
#    endif //BOOST_XPRESSIVE_FUSION_V2
#endif //BOOST_VERSION

I also executed your examples from the boost/lib directory and they produced in both cases same results. Your answer today is highly appreciated, since I will be on vacation from tomorrow on.

thanks,
Ovanes


On 9/24/07, Ovanes Markarian < om_boost@keywallet.com> wrote:
Eric,

sorry for the delay. I only now found some time to work on that issue:
http://lists.boost.org/boost-users/2007/08/30120.php


After analysing your post and investigation what's going on, I would like to write my opinion:

changing xpressive_fwd.hpp or proto_fwd.will not help.

I grepped where fusion includes are used and need to enclose these in some conditional statements:

#ifdef BOOST_XPRESSIVE_FUSION_V2
#    include ... //fusion 2 headers
#else
#    include ... // fusion 1 headers
#endif

Actually this can be done using some kind of a macro function like:

#include BOOST_XPRESSIVE_FUSION_ROOT(sequence/cons.hpp)
...

The macro function will deliver the root dependent on the predefined macros like:
1. if !defined XPRESSIVE_FUSION_ROOT and use V2
    => choose the root for V2
else => choose the root for V1

As I found out the following files need to be changed:
linker.hpp
alternate_matcher.hpp
alt_compilers.hpp
any.hpp
cons.hpp
arg_traits.hpp
op_base.hpp
proto_fwd.hpp

If you give me your green light I will do it and submit a patch.


With Kind Regards,
Ovanes