Boost logo

Boost :

Subject: Re: [boost] Boost policy for putting headers in boost/ Was: #3541 Support <boost/ptr_map.hpp>
From: Joel de Guzman (joel_at_[hidden])
Date: 2009-10-28 13:33:07


Stewart, Robert wrote:
> Joel de Guzman wrote:
>>> on Mon Oct 26 2009, Joel de Guzman
>> <joel-AT-boost-consulting.com> wrote:
>>>> FWIW, we've solved that by having a flat include
>>>> directory. It's the
>>>> include/ dir you see up there. The directory contains all
>>>> forwarding
>>>> headers. For instance, see http://tinyurl.com/yj86r8v. You have:
>>>>
>>>> #include <boost/fusion/include/deref.hpp>
>>>>
>>>> in addition to the modular:
>>>>
>>>> #include <boost/fusion/iterator/deref.hpp>
> [snip]
>> I also advocate consistency. That is why I chose that structure.
>> It's not different at all, if you think in terms of modularity.
>> Boost is a set of libraries; each library is composed of smaller
>> sub-libraries or components, and so on. The (outermost) main boost
>> goes like this:
>>
>> boost/
>> libx/
>> liby/
>> libx.hpp
>> liby.hpp
>>
>> Some libraries, especially the bigger ones really ought to
>> be broken down into sub-libraries or modules. Following the
>> main header convention, it goes the same for sub-libraries,
>> e.g.:
>>
>> boost/
>> libx/
>> modx/
>> mody/
>> modx.hpp
>> mody.hpp
>> liby/
>> libx.hpp
>> liby.hpp
>
> That is reasonable and defensible, but argues against your include directory.

To be very honest with you, I don't quite like flat includes.
That's a bit short of saying, I agree with you. But it's a
reasonable compromise, I would say. Some folks just don't
want the burden of having to think in terms of modules and
includes.

Regards,

-- 
Joel de Guzman
http://www.boostpro.com
http://spirit.sf.net
http://www.facebook.com/djowel
Meet me at BoostCon
http://www.boostcon.com/home
http://www.facebook.com/boostcon

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk