As I sit in the C++ Standards committee meetings, they are discussing the pros and cons of dropping Inheriting Constructors since no compiler vendor has implemented it yet (the sense being users haven't been asking for it).
Let me quickly remind everyone what inheriting constructors are:
struct B
{
B(int);
};
struct D : B
{
using B::B;
};
Some vendors are proposing that with r-value references and variadic templates (perfect forwarding constructors), it would be trivial to provide a forwarding constructor in the inheriting class that would obviate inheriting constructors.
For e.g.:
struct D : B
{
template<class ... Args>
D(Args&& ... args) : B(args...) { }
};
I have two questions:
1) Can you provide real world (non-contrived) examples from your programming experience that would benefit significantly from inheriting constructors?
2) Are there any technical reasons you can think of that would preclude "perfect forwarding constructors" from being an adequate alternative?
Thanks!