Access to own private constructors via derived class constructor inheritance

前端 未结 0 419
攒了一身酷
攒了一身酷 2020-12-16 16:15

Consider:

struct B {
    void f();
private:
    B(int, int = 0);
};
struct D : B { using B::B; };
void B::f() {
    auto a = D{0};
    auto b = D(0);
    auto         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题