Boost logo

Boost :

Subject: Re: [boost] Boost policy for putting headers in boost/ Was: #3541 Support <boost/ptr_map.hpp>
From: joel (joel.falcou_at_[hidden])
Date: 2009-10-28 03:32:01


David Abrahams 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>
>>
> Oh yeah, I forgot about that. Not bad, but the problem is... I tend to
> forget it. So I reach for boost/fusion/deref.hpp as though all
> libraries use that convention, and I am slowed down until I can remind
> myself that fusion is different. Consistency in these little things
> goes a long way toward ease-of-use.
>
Just tossing my own experience here. In my own projects I am following
this structure:

* all public files in a given module is in
  #include <lib/module/file.hpp>

* all implementation details files in a given module are in
  #include <lib/module/impl/file.hpp>

* there is a short-cut header that includes all mandatories (but not the
optional) files of a given module in a include/ folder
  #include <lib/include/module.hpp>

I never had the need to have a repeat of each include file of module fil
into include tough.

-- 
___________________________________________
Joel Falcou - Assistant Professor
PARALL Team - LRI - Universite Paris Sud XI
Tel : (+33)1 69 15 66 35

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