[comp.lang.c++] calling a generated copy constructor

hitz@sim5.csi.uottawa.ca (Martin Hitz) (04/23/91)

The ARM specifies exactly how copy constructors are generated by
the compiler, if they are not explicitely specified. Moreover,
it even distinguishes between declaration and definition of a generated
copy constructor (page 296).

However, g++ refuses to compile

class X {};
main()
{
	X x;
	X y(x);
}

x.cc: In function int main ():
x.cc:5: constructor syntax used, but no constructor declared for type `X'

Is this considered a bug?

Martin Hitz (hitz@csi.uottawa.ca)