I understand that if I define a constructor, then the compiler won't
synthesize any constructor for me. How about copy constructor and
assignment operator? WIll compiler stop synthesizing any of them if I
declare a constructor or something else?
No - it will create defaults for any one you do not define yourself.
It's a bit more complicated than that. If you write any of your own
constructors, the compiler will not generate a default constructor for
you (see 12.1/5). Also, if you have a template constructor taking a
single parameter, I believe that the compiler will still generate an
implicit copy constructor even if the template version would otherwise
be able to take the same parameter as the copy constructor. Anyone
able to provide evidence for or against this in the standard? The
closest I can find is 14.5.2/2, but that is talking about which one is
called when a template and non-template member function are both
present with the same name, not constructors specifically.
--
Computational Fluid Dynamics, CSIRO (CMIS)
Melbourne, Australia