15 Jun
2014
15 Jun
'14
12:13 p.m.
John Maddock wrote:
IMO we need a better way of looking at dependencies, perhaps by marking up glue headers as optional.
This approach causes difficulties down the road. module X X.hpp module Y Y1.hpp Y2.hpp (optional) includes X.hpp module Z Z.hpp includes Y2.hpp Does Z depend, indirectly, on X? If your answer is yes, and it must be, remember that Y does not depend on X, so the secondary dependencies are no longer the transitive closure of the primary dependencies. The tool can be made to figure these things out, but to do so, it will need to create virtual submodules, one per each optional header. Either that, or scrap the whole module-level dependency approach and start tracking individual headers.