On Fri, 24 Jan 2003 13:53:00 -0800, "Paul Mensonides" <[EMAIL PROTECTED]> wrote: > > ----- Original Message ----- > From: "Hugo Duncan" <[EMAIL PROTECTED]> >
> > I am including files using BOOST_PP_ITERATE. One of the files > > that I include happens itself to include boost/mpl/list.hpp. > > I'm not sure what you mean here. If you are iterating over a file (or > section of a file) with the file-iteration mechanism. That iterated text > should *never* include regular headers. Paul, I was not aware of that restriction - it doesn't seem to be mentioned in the docs. > [Snipped example] > > It is defined when the file-iteration mechanism is iterating over a file. > Its purpose is to distinguish between a normal inclusion and an "iteration" > inclusion so that the same file can iterate over itself. When a file that > is iterated includes other files *during an iteration*, > BOOST_PP_IS_ITERATING is still defined and the other files probably won't > know how to handle it. (<boost/mpl/list.hpp> is one example of this.) The > solution is simply to not include any files during a particular iteration. This, for me, is a nuisance, as the files that I am including through ITERATE are included individualy at times, and could add header dependencies that I do not know about elsewhere. The reason for my using ITERATE is to be able to provide an extensible list of files to include as a single extension/maintenance point for my library, so having to write 2.hpp reduces the incentive to use ITERATE in the first place. I still think that this could be solved by checking something like the following in <boost/mpl/list.hpp> #if !BOOST_PP_IS_ITERATING || !BOOST_MPL_PREPROCESSING_MODE Hugo _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost