Edward Diener wrote:
Let me give a very simple practical use case and this will illustrate what I am trying to discuss.
I develop library EDS_LIB and it is a Boost library which must be built as a library and is not header-only, and my library uses regex in some interface it exports.
I have a decision to make: do I use Boost.regex and therefore work in any C++ mode or do I use std::regex and therefore works only in C++11 mode ( which I will assume supports the std::regex library ). Most people will say to use Boost.regex and be able to support any mode. Fair enough, but now EDS_LIB depends on Boost regex.
And what is the use case in which you don't have Boost.Regex but do have Boost.Config so that you can use your proposed mechanism? If your library is not part of the Boost distribution, it might make sense for your library to support building without Boost, in which case one would expect your library to not need Boost.Config, wouldn't one? And if your library is part of the Boost distribution, one would expect Boost.Regex to also be present, wouldn't one?
If Boost ever goes to a more modular distribution all distribution of EDS_LIB must also include Boost regex.
Right. But this isn't the case now.