Why constructor is not called for given casting operator?

后端 未结 4 1341
南旧
南旧 2021-01-18 09:23
struct A {}; 
struct B
{
  B (A* pA) {}
  B& operator = (A* pA) { return *this; }
};

template
struct Wrap
{
  T *x; 
  operator T* () { return         


        
4条回答
提交回复
热议问题