class A{ public: }; A x; // OK A y(1); //OK I can't found that standard says: default constructor with argument INT. By code protection I will write: class A{ A(); // w/o definition A(int); // w/o definition public: }; What to do?
t.C:5:6: error: no matching function for call to ‘A::A(int)’ t.C:1:8: note: candidates are: A::A() t.C:1:8: note: A::A(const A&) your code example is rejected as it should.
found silent conversion class A have explicit A(std::complex<long double>const& x);