Assuming I have this code:
class MyClass {
private:
class NestedPrivClass {};
public:
MyClass(NestedPrivClass){}
};
Is there a way for another class to create an instance of MyClass
by calling the public constructor?
Shouldn't using private nested class as parameters in public functions be a compilation error? (As it is impossible to call them.)