Hi,
Is it legal and ok to use 'this' in a constructor as follows:
Class A {
public:
A() : pimpl_(0) {
pimpl_ = new AImpl(this);
}
private:
struct AImpl;
AImpl* pimpl_;
};
Thanks.
Is it legal and ok to use 'this' in a constructor as follows:
Class A {
public:
A() : pimpl_(0) {
pimpl_ = new AImpl(this);
}
private:
struct AImpl;
AImpl* pimpl_;
};
Thanks.
Comment